Note: The method below is known as “RBF” (Replace By Fee). The procedural steps and their accompanying screenshots were completed in Trust Wallet's app on a Samsung Galaxy S20+ running Android 10. Other wallets likely support this method and the process should be similar for those other than Trust, however, consult your wallet’s manual or support staff for its specific capabilities and proper procedures.
So, you tried to send some Ethereum, and your transaction is stuck on pending. It has been for hours, and you don’t know what to do. You start calling yourself an idiot because you have no idea why it’s stuck and you begin thinking: Maybe this whole cryptocurrency thing is a bit beyond my knowledge. Can’t fix something you "broke" when you don’t even know why it happened in the first place. “Once you send it, you can’t reverse the transaction”… the cryptocurrency tagline repeats over and over in your mind. Your final thoughts before going beastmode and doing a whole “Hulk Smash” thing on your computer or phone is: “I’m screwed. My Ethereum is lost. I’m such a dumbass.”
Yes, maybe you are a dumbass. Yes, maybe this whole cryptocurrency thing is beyond your knowledge and you should rethink the self-management of funds. Leave it to someone who actually knows what they are doing. However, oftentimes, knowledge is power and can save your dumbass once in a while. You are more than likely one of the many intermediate cryptocurrency users who knows enough to speak intelligently about the principles of cryptocurrency and have a basic level technical know-how of sending and receiving tokens, but you do not grasp the computing and financial nuances behind the scenes. The ironic thing is, in this case, the very basis of your little quandary is simple, and no different from that of any other financial ecosystem.
While you might think you are 100% self managing your funds, you are not. You think the token you are sending goes from point a to point b without any help? Well, if you actually think that way, then you definitely are a dumbass and shouldn’t be managing your own funds. Cryptocurrency is decentralized (in most cases) in the sense that there is no governing authority which exercises full control over your transactions. However, all transactions do require another party or parties to facilitate and confirm. This guide will not only answer the question of why your transaction was stuck in the digital abyss to begin with, but will also solve your dilemma and get the Ethereum back in your possession.
Getting back to the problem at hand: You’ve sent ether to another wallet address, the transaction will not process and it is stuck as pending in your wallet. Upon clicking the transaction ID, etherscan will give you the nitty-gritty, bare-bones details, and maybe your stuck transaction’s details look something like this:
So much for the lightning network right? (Note: I am aware the lightning network does not apply to Ethereum, no need for know-it-all type commentary). Here is what has happened. You aren’t paying the miners enough gas to process the transaction you are requesting. So surprise surprise! The reason behind this little financial quandary you are in, has to do with money, and how much you are willing to pay. In the transaction you have initiated, the gas price (gas is the fuel, or more aptly, the bit of ether you pay the miner to process your transaction) was not set high enough for it to be considered prioritized on the network queue, and will more than likely be pushed lower and lower down as more transactions come through that have allotted an appropriate gas amount. So your request is in line to be completed, but that estimated confirmation duration will more than likely only go higher and higher. Your transaction will probably be stuck for days, weeks, or months in the digital abyss.
If this happens in Trust Wallet, here’s how you undo it:
With whatever wallet you’ve used for this transaction, copy the public wallet address used to receive Ethereum.
Note: The entire procedure below is to be completed within the wallet the pending transaction originated from.
On the transaction that is stuck and remains pending in your wallet queue, open the transaction details and note the nonce number.
Initiate a new transaction, sending 0 ETH to the public wallet address you copied in step 1 (your wallet address). In essence, you are going to be sending 0 Ethereum to yourself.
Before confirming the transaction, open the advanced options (little gear icon in top right), and change the nonce number of this transaction to match the nonce of the transaction that is stuck. In this case 8. Modify the gas amount appropriately. The numbers utilized below worked when the screenshots were taken, however, as of the date of this publication, it would be more suitable utilizing approximately 95 gwei (as of 08/13/2020) to guarantee the transaction being confirmed in an appropriate amount of time (current cost is about $0.90 worth of Ethereum).
NOTE: The gas price inputted for this transaction MUST be greater than the amount utilized for the stuck transaction, hence the name of this procedure, Replace By Fee. The ability to replace the pending transaction depends on the new transaction being initiated having a higher fee, thereby dropping the former, and replacing with the latter. Typically, unless you’ve modified advanced options, the wallet you are using will determine a default gas amount that is suitable for the network at the time of sending in order to properly prioritize your transaction. For more information see etherscan’s gas tracker, which reports current and historical Gwei prices for specifics on setting appropriate gas amounts for transactions,and provides current costs of Gwei: https://etherscan.io/gasTracker
Also, the pending transaction you hope to replace must have ZERO NETWORK CONFIRMATIONS. If even one confirmation has occurred this method will not work.
Confirm and send transaction. Within a few minutes the pending transaction should be replaced with this one. If you check the status of the former “stuck” transaction on etherscan, it should now show this status if performed correctly:
Viola! Problem averted. They say there are no countries in the cryptocurrency world and I believe that to be true. In the cryptocurrency world, the best nation is a donation. Feel free to make one if this saved your dumbass.
NOTE: This is NOT a transaction reversal. There is no (legitimate) way to reverse, or “undo”, any cryptocurrency transaction once a network confirmation has occurred. With a transaction such as this, its initiation, subsequent drop and ultimate replacement, will remain as a record on the blockchain. However for all intents and purposes, and as far as the distributed ledger is concerned, this transaction never happened since it was never confirmed by the network.
Again, for this method to work, the pending transaction must have ZERO NETWORK CONFIRMATIONS and the WALLET used for the transfer that is stuck on pending MUST SUPPORT RBF (Replace By Fee) transactions. Also, gas amounts required for transacting ethereum are quickly on the rise, the screenshots above were only taken about a month ago, and 50 gwei was suitable for a typical transaction, and presently, it most definitely is not a suitable amount. Please check etherscan's gas tracker here, or use your wallet's default values for guidance in order to allocate an appropriate amount of gwei for transactions to be properly prioritized on the network.