Connect to EVM networks
Use @metamask/connect-evm to connect your dapp to Ethereum and other EVM networks in the MetaMask mobile app
or browser extension.
The MetaMask Connect EVM client provides an EIP-1193-compatible
provider with the same shape as window.ethereum, meaning existing viem, ethers.js, or web3.js
code works with minimal changes.
MetaMask Connect also includes automatic platform detection, relay-based connections, and session persistence.
If your dapp supports both EVM and Solana, use both the EVM and Solana clients. They share the same underlying multichain session, meaning the user only approves once.
Supported platforms and libraries
MetaMask Connect supports multiple integration paths. You can install it from npm, use it through developer libraries such as Wagmi, or integrate it through supported third-party libraries.
Choose a quickstart based on your stack.
Library compatibility
The EVM client works seamlessly with popular Ethereum libraries:
| Library | Compatibility |
|---|---|
| viem | Use with custom() transport |
| ethers.js | Pass client.getProvider() to BrowserProvider |
| web3.js | Pass client.getProvider() to Web3 constructor |