Crypto Flash Servise Sell Tokens and NFT

Crypto Flash Servise Sell Tokens and NFT

Menu flash coin

How to cancel a bitcoin transaction

bitcoin core
bitcoin core

Everyone knows that bitcoin transactions cannot be reversed. 

Transaction irreversibility is one of the distinguishing features of a peer-to-peer cash system - unlike centralized payment systems. At one time Bitcoin Core developers were going to change the client to allow editing a transaction not yet accepted into the block to change the commission, but this functionality has not been implemented yet. Nevertheless, it is already possible to cancel a transaction under certain conditions and if you want to.

This article describes an experiment designed to test how low commissions can be successfully sent with Bitcoins from a Bitcoin Core wallet. The experiment was unsuccessful and resulted in five transactions sent with a variety of wallet commission settings being "hung". But then the experimenter managed to undo the hanged transactions with a refund of the blocked amounts.

How not to send transactions

The first 2 transactions tried to send with a minimum fee of 0.00001 BTC and a checkbox "Try to send without commission if possible".

Note that the client recommends 0.00013615 BTC per kilobyte. But for the remaining three transactions, each of which was for the same amount of 0.01 BTC, the recommendation regarding the amount of commission was ignored, and the amount of commission itself was deliberately set lower than the recommended amount.

It turned out that all five transactions hung without confirmation for an indefinite time. In our case a week.

An additional inconvenience was that the address to which the bitcoins were sent, in turn, could not be used to send bitcoins. An attempt to make a transfer was accompanied by a message: "Oops! You have unconfirmed deposits pending. You must wait for your deposits to be confirmed before withdrawing."

If the situation is familiar to you, then there is no reason to panic. You can wait for a while, for starters. If the queue of transactions dries up, then perhaps, at the end, it will come to yours. If the wait is too long - as in our case, for a week, you can try to make the wallet - here this was done using Bitcoin Core as an example - "forget" about the posted transactions. After all, until the first confirmation came - the transaction is not in the block, which means that only your client knows about it.

How to rollback a pending transaction!

Make sure the transaction is pending. Open Block Explorer and check that they don't know anything about the pending transaction and that there is actually money in the account. Even in case blockchain.info shows the transaction and draws a red button,all is not yet lost.

In the wallet, go to the debug console (Help - Debug window - Console)

If the wallet is encrypted, first you need to get access using the walletpassphrase command.

Now we have to get the private key of the desired address. The dumpprivkey . Instead of must be substituted the address, which was used to send the funds. As a result you will get a private key for the specified address. It should be copied somewhere, you will need it. If the transaction was complex, and bitcoins were taken from multiple accounts, then you need to export the private keys for all those addresses. Never keep your private keys in a place accessible to anyone. Knowing your key gives you full access to the account that corresponds to it. Also, note that every command in debug mode in the console gets a response. It may be blank, but it is always there.

If other addresses have bitcoins, the private keys of those addresses also need to be exported.

After you finish exporting keys, close the client and delete the wallet. The location of the wallet (wallet.dat) depends on the particular client and OS. Naturally, you should not remove it at all, but rather rename it or move it to a safe place.

Now restart the client. It will re-create the wallet. It must import the previously obtained key(s). Go to the debug console and write importprivkey . The import can take quite a long time, but in any case let it finish - wait for a response to the command.

In the new wallet should appear the account with its real state. Unconfirmed transactions are "forgotten", funds blocked earlier are available for sending again. Now you can send them again, but this time don't forget to include the recommended fee.

For the client, where there is no functionality to calculate the recommended commission amount, you can use the service Blocktrail. A client that not only does not show, but also does not provide the ability to set the fee, you can use at your own risk.

Cancellation of pending transactions sent using wallets other than Bitcoin Core is done similarly. It is important to export the private keys of all the addresses that participated in the transactions and have bitcoins, then recreate the wallet - to do that, you will probably have to delete the directory where the wallet program stores the data, and then import the private keys into the newly created wallet. The solution is not applicable to cloud wallets.

Sort Denis
Cookie settings
This site uses cookies to offer you a better browsing experience.
You can accept them all, or choose the kinds of cookies you are happy to allow.
Privacy settings
Choose which cookies you wish to allow while you browse this website. Please note that some cookies cannot be turned off, because without them the website would not function.
Essential
To prevent spam this site uses Google Recaptcha in its contact forms.

This site may also use cookies for ecommerce and payment systems which are essential for the website to function properly.
Google Services
This site uses cookies from Google to access data such as the pages you visit and your IP address. Google services on this website may include:

- Google Maps
- Google Fonts
Data Driven
This site may use cookies to record visitor behavior, monitor ad conversions, and create audiences, including from:

- Google Analytics
- Google Ads conversion tracking
- Facebook (Meta Pixel)