top of page

How to Cancel or Replace a Pending Ethereum Transaction?



 

TL;DR


It takes some time for the Ethereum network to process your transaction. The waiting game is a bit like being at the doctor's office, except without the assurance you won't be charged an arm and a leg. The reasoon why Ethereum networks takes time to process a transaction is because of the way miners prioritize transactions. They do it off a higher fee based systems, where those who offer more get prioritized over those who offer less.


Ethereum transactions can sometimes get stuck due to low gas fees. This can be frustrating, especially if you've been waiting for a few days and it's not processing at all. But don't worry, there's an easy way out! You can simply replace the pending transaction and submit a new one with higher fees.


Introduction


When replacing a transaction, it is important to note that you can only do this for pending transactions. You can't replace, revert, or cancel any transaction that has been confirmed. Keeping that in mind, during times of high network congestion some cryptocurrency transactions can get stuck. When volumes of crypto transactions are too high, you could find yourself with a pending transaction that could last hours or days.


If your Ethereum transaction is pending for a long time, you can wait for the blockages to clear on their own-happens if the gas fees decreased or the pending transaction failed. If these two don't occur, don't worry, there are steps you can take to clear the pending transation. The process invovles setting up a new one that pays higher gas fee.


In the following guide, we will show you how to cancel or replace a pending ethereum transaction on MetaMask. You could also use other crypto wallets that support the Ethereum blockchain. Keep in mind it might be slightly difference.


What Makes An Ethereum Transaction Get Stuck?


The way Ethereum is setup is through a bidding system for your transaction fees. The complexity of your transaction will determine the fee (how much computational power it needs).


The gas cost will be determined by the complexity of your transaction. However, you can change your gas price and gas limit. The total fee will work as an incentive for miners. Keep in mind if your fee is too low the miners will prioritize other higher fees. Further, by being outbidded your transaction could be stuck in pending mode.


Further, if your transaction is stuck in pending mode, Ethereum will not confirm any new transactions you make from the wallet address until the first transaction, the one stuck in pending, is confirmed.


Requirements Before We Start

  • Internet Access

  • MetaMask Installed

  • Seed Phrase to Log Into MetaMask

How To Replace a Pending Transaction on MetaMask


Log Into MetaMask


First you need to log into your MetaMask wallet that has a pending transaction. If your pending transaction is in an external wallet, then you can import it through your seed phrase.

Find Pending Acitivity


Once you log into/import your wallet with the seed phrase, find the pending transaction by clicking the [Activity] tab. Get the details and write down the [Nonce] value.


*If you have multiple transactions pending, start with the oldest one first. Search for the one with the lowest [nonce] value.

Navigate To Setting


Next, navigate over to [Setting] and click on [Advanced].

Customize Transaction Nonce


Scroll down to [Customize transaction nonce] and turn it on.

Copy Wallet Address


Go and copy your wallet address onto your clipboard.

Create New Transaction


Go over and click on [Send] to create a new transaction. Then paste your wallet address in the [Add Recipient] field.

Send 0 ETH To Your Address


You need to send 0 ETH to your wallet address using the nonce of the pending transaction. Make sure you take note of that. Click on [Confrim] when you are ready to send the transaction.


*Note the transaction could get stuck if you set a low gas price. Make sure to set a reasonable amount.

Confirmation


Once you [Confirm] the transaction, wait a couple of minutes until the pending one gets replaced. Congrats, your pending transaction has now been replaced.


Once it has been confirmed go back to [Customize transaction nonce] and turn it off to avoid any future accidents.


Final Thoughts


The Ethereum transaction fee is the price that you pay to get your transaction confirmed by miners. If you set a too low gas price, it may not be enough for the miners to even confirm your transaction and put it in the next block.


If your transaction gets stuck and has been pending for hours, then you can replace that pending transaction by making a second one. To replace the original pending transaction follow the steps above, then pay the sufficient gas fees needed to successfully push through the canceling transaction .

Comments


bottom of page