Skip to content

MetaMask/metamask-sdk

Repository files navigation

MetaMask SDK

codecov

MetaMask SDK enables developers to easily connect their dapps with the MetaMask browser extension and MetaMask Mobile.

It supports the following dapp platforms:

Read more about setting up MetaMask SDK and MetaMask SDK concepts.

This repository contains the JavaScript SDK and examples. You can also see the Android SDK repository and the iOS SDK repository.

Features

  • Session persistence
  • Multi MetaMask provider (let user choose between browser extension and mobile wallet)
  • Batch RPC calls (send multiple requests to your wallet at once)
  • Read-only RPC calls and Infura integration
  • Wagmi hook integration (alpha)
  • i18n
  • Full modal UI customization
  • Smart contract library (coming soon)

Get started

Install the SDK:

yarn add @metamask/sdk

or

npm i @metamask/sdk

Web dapps

See the following examples:

Read the documentation for using the SDK with JavaScript for more information.

React Native

We recommend using React Native v0.71.4 or higher to avoid performance issues on Android.

See the React Native example and read the documentation for using the SDK with React Native for more information.

Node.js

See the Node.js example and read the documentation for using the SDK with Node.js for more information.

Electron

See the Electron example and read the documentation for using the SDK with Electron for more information.

SDK options

See the full list of JavaScript SDK options.

Contributing

To contribute to MetaMask SDK, see the contribution guidelines.

Contacts

Fill out this form for a complimentary design optimization workshop.