Change Metamask Address in Extension and in Dapp

Hello dev community!
I am working on MetaMask build and wanted to change the current selected address to my custom address (Valid ethereum address) on extension and on dapp. Keeping in mind that I want to do it for viewing purpose for the user, and user will use the already connected account’s private key for transactions.
Also heard about the MetaMask flask build, but not sure about it.
Can anyone point out the code snippet or file from which I can reach the above result, as I have searched for it but failed to do so.
It’s an urgent task and any kind of help would be highly appreciated. Thank you

@ibm360

Hi, do you want DAPP to display current connected wallet address ?

1 Like

Hi @ibm360 ,

Have you gone through the MetaMask docs for this info?

There is also section on Snaps in the same docs as above, as well as a link to Flask (which is needed to try Snaps); https://metamask.io/flask/

3 Likes