A Bitcoin transaction can be a mysterium. It could take hours for it to get confirmed if you used too low or no transaction fees. So, can a Bitcoin transaction be unconfirmed forever?
No, if your transaction is unconfirmed for too long, it will disappear from the network. That means nodes will remove this transaction from the Mempool. The Mempool is the pool for unconfirmed Bitcoin transactions.
But, if only one node alone forgets or removes the transaction from the Mempool, it is not enough. All nodes have to remove the transaction from the pool of unconfirmed transactions.
The reason for that is because one node could go offline. But, this doesn’t mean that the network forgot your transaction. Many nodes store your transaction once you submit it to the network.
How long does it take until nodes forget my unconfirmed transaction?
It could take days or even weeks. There is no exact time when your transaction will disappear from the network. That is also one of the reasons why you should always set a transaction fee. Never send BTC with zero transaction fees.
The state of a Bitcoin transaction
The state of a Bitcoin transaction is binary, so confirmed or unconfirmed. If it’s confirmed, it means that the opponent got the money, if not, it means the sender still owns the coins.
If you submit a transaction to a crypto network, it goes into the Mempool. The Mempool is the pool for all unconfirmed transactions in the memory of a computer. Also, other nodes share your transaction with the network. So, other nodes can also store your transaction in their Mempool.
Because of that reason, you can go to block explorers and check if your transaction is confirmed yet. They stored your transaction in their Mempool.
If a miner finds the right hash for a new block, he can choose what transactions go from the Mempool in a new block. They focus on the ones that have the highest transaction fees to gain more Bitcoins. Miners not only get the fixed block reward, but they also get all transaction fees within a block.
If your transaction is in the Mempool, you still own the Bitcoins. If a miner took the transaction and included it in a block, you sent Bitcoins to the other person.
So, if your transaction disappeared from the network, you didn’t lose the money. It means you never made the transaction. Afterward, you could make a new transaction with a higher transaction fee. It gets confirmed in the future by miners that put your transaction on the blockchain.
The size of the Mempool and why it matters
The size of the Mempool is crucial when it comes to how long you have to wait until your transaction is confirmed. It is also an indicator of how much you have to pay.
The Bitcoin network can handle on average 7 transactions per second. What would happen if users submit more transactions than the Bitcoin network can handle? Let’s say users would submit 8 new transactions to the Bitcoin network.
New transactions would fill up the Mempool and the Bitcoin network can’t keep up anymore. The Mempool would grow and grow. As a result, transactions are stuck. Users who submit new transactions to the network have to pay higher transaction fees. Transaction fees would explode.
Old transactions that paid a smaller amount as transaction fees would be stuck for hours or days. Nodes forget these transactions. Users can submit a new transaction with higher transaction fees.
If you want to pay a smaller amount of transaction fees, look for patterns in the size of a cryptocurrency Mempool. If the Mempool is not that big, there is less competition. This means you can pay less for transaction fees. Also, your transaction is confirmed faster. Check out this site to find patterns in the Bitcoin Mempool.
Can an unconfirmed transaction be canceled?
No, once submitted to the network, a Bitcoin transaction can not be canceled. It could disappear from the network if it takes too long, but you can’t control this process.
Think about it like this. If you submit a new transaction to the Bitcoin network, you tell hundreds of other computers (nodes) that you want to make this transaction. These nodes take the transaction and put it into their Mempool.
You would have to go to every single node and it would have to remove your transaction from the Mempool. You don’t even know which nodes know about your transaction and who operates them. That’s the reason why you can’t cancel an unconfirmed Bitcoin transaction.
What is the longest a Bitcoin transaction could take?
There is no precise time what the longest time is that a Bitcoin transaction could take. There are three different components when it comes to how long it takes until a Bitcoin transaction is confirmed.
- When do miners find a new right hash?
- How big is the Mempool
- How much transaction fees did a transaction pay
The Bitcoin protocol is designed in such a way that miners find a new block every 10 minutes. The protocol adjusts the difficulty of finding a new block every 14 days. Depending on how much hash rate there is in a network, the difficulty increases or decreases. The Bitcoin protocol adjusts the difficulty value in such a way that the block time stays at 10 minutes.
But, because there is a random factor, miners sometimes find the right hash after 8 or 9 minutes. On the other side, there are times when miners need 11 or 12 minutes until they find a new block.
Also, if the Mempool is bigger, it usually takes longer until your transaction is confirmed. A significant factor is also how much you paid for transaction fees. If you paid more, miners focus on your transaction and confirm it faster.