Double-spending is an attempt to use the same units of cryptocurrency more than once. Because digital information can be copied, a blockchain must determine which conflicting transaction is valid and which one should be rejected.

Blockchains prevent double-spending through consensus. Network nodes verify whether funds are available and process transactions according to protocol rules. Once a transaction is included in a block and receives sufficient confirmations, the probability of replacing it normally decreases.

How double-spending can occur

An attacker may attempt to send the same amount to two recipients or create an alternative blockchain history after making a payment. Under normal operation, conflicting transactions cannot both spend the same underlying resource. One must be rejected, become invalid, or fail to become part of the accepted chain.

A major scenario involves a 51% attack, where an attacker obtains substantial control over block production. Other scenarios can involve network-level attacks or weaknesses in finality mechanisms.

Double-spending is different from an ordinary user mistake. Sending funds to the wrong wallet address is not double-spending. It is a valid transaction that the sender wishes they could reverse. Double-spending specifically involves attempting to have multiple conflicting expenditures of the same balance recognized.

Preventing double-spending is one of the fundamental problems solved by blockchain systems. The security of the consensus mechanism, participant distribution, and finality rules therefore directly affect the reliability of a cryptocurrency network.