1

Is Metamask a web3 provider? I am aware it is a wallet. But is it also a web3 provider?

I have read from here that:

Web3 provider is a website running geth or parity node which talks to Ethereum network.

Then I have read here that:

Web3Modal is an easy-to-use library to help developers add support for multiple providers in their apps with a simple customizable configuration.

What do you call Metamask, Dapper, Gnosis Safe, Frame and the rest? Are they web3Providers? Or what are they?

I am asking this line of code here:

const provider = await web3Modal.connect();

const web3 = new Web3(provider)

// what is provider and why should I pass it to a new instantiation of web3?

;

1

Is Metamask a web3 provider?

Yes.

Web3 provider is a website running geth or parity node which talks to Ethereum network.

In the answer you've pointed to, when he says "website", he really means "RPC endpoint" (you'll see his path contains the string "api"), where the endpoint will likely be on a back end server running an Ethereum node.

The endpoint - i.e. path for connecting to a client node - is "provided" in one of two ways:

  • Built directly into your front end via a library (e.g. Authereum), or
  • Injected into the front end by the browser or browser add-on (e.g. Metamask).

Web3Modal allows you to handle both of these, and have the user pick the one they want to use.

4
  • When it is built directly to your front end how do users interact with your dapp? Do they still use Metamask? – YulePale Apr 16 at 17:31
  • No, there's a different interface. For example, if you use Authereum, you build the Authereum package into your front end code (npm install authereum, then include the appropriate code), when you connect the wallet you'll be presented with the Authereum pop-up instead of Metamask. – Richard Horrocks Apr 16 at 17:34
  • Will the user require an Authereum browser extension like the way we use metamask? – YulePale Apr 16 at 17:38
  • 1
    No, for any providers you build into the front end code, they should generate their own pop-up interface when a user clicks "connect". Browser extensions would normally be used for providers that inject. – Richard Horrocks Apr 16 at 17:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.