Reset MetaMask nonce

胡家維 Hu Kenneth
Singapore Blockchain-Dapps
2 min readJan 4, 2019

I encounter an issue about Nonce.

I am developing on Ganache and am using Metamask to send transactions to simulate user behavior with the app. Now here’s the issue. If I restart Ganache it resets all accounts. However, Metamask keeps the old transactions in it’s memory and thinks the nonce of a new transaction is nonzero as the following information:

Error Message : ALERT: [ethjs-rpc] rpc error with payload {“id”:7510096062578,”jsonrpc”:”2.0",”params”:[“0xf86e338504a817c80082520894f2d15deaf62b8c4afc0343006579e8e662c120d9888ac7230489e8000080822d45a0140a687bb66922e24d987acb1b11d52aef279c8393ff788cb3f550a29438d8aaa064446c33d23f8cff97449e6e246ba739638a21e7c52cd30d8cae9b1d50b2d7a7”],”method”:”eth_sendRawTransaction”} Error: the tx doesn’t have the correct nonce. account has nonce of: 0 tx has nonce of: 51

Solution : Reset MetaMask Account. It will not affect your account in other network.

  1. Select the account which you want to reset.

2. Select “Setting” option

3. scroll down to “Reset Account” section and then click “RESET ACCOUNT”

4. Click “RESET” button

5. All history is gone on main page.

6. All histories in other networks still remains

--

--

胡家維 Hu Kenneth
Singapore Blockchain-Dapps

撰寫任何事情,O型水瓶混魔羯,咖啡愛好者,Full stack/blockchain Web3 developer,Founder of Blockchain&Dapps meetup ,Udemy teacher。 My Linktree: https://linktr.ee/kennethhutw