Technical definition
In UTXO-based blockchains, funds are not stored as balances in accounts but as discrete outputs from previous transactions. Each UTXO is a tuple containing an amount of cryptocurrency and a locking script (e.g., a public key hash) that specifies the conditions under which the output can be spent. When a transaction is created, it consumes one or more existing UTXOs as inputs and creates new UTXOs as outputs. The sum of input UTXOs must equal or exceed the sum of output UTXOs, with the difference typically representing a transaction fee. This model ensures that all transactions are deterministic and that double-spending is prevented without requiring global state tracking.
An analogy
Think of UTXOs like physical coins in your pocket. Each coin is a separate item with a specific value, and when you spend money, you hand over one or more coins to the recipient. The recipient now holds those coins, and you no longer have them. Similarly, UTXOs are individual 'coins' of cryptocurrency that are transferred between parties in transactions.
Why it matters
The UTXO model provides a transparent and auditable way to track the flow of funds without relying on centralized account balances. It enhances security by making double-spending attacks computationally infeasible and enables simpler verification of transaction validity.
Where it came from
The UTXO model was introduced with Bitcoin in 2009 by Satoshi Nakamoto. It was inspired by earlier cryptographic payment systems like Adam Back's Hashcash and Wei Dai's b-money, which also used unspent transaction concepts to track value.
Example in practice
Alice receives 0.5 BTC from Bob in a transaction. This creates a UTXO of 0.5 BTC locked to Alice's public key. Later, Alice wants to send 0.3 BTC to Charlie. She creates a transaction that spends the 0.5 BTC UTXO (as input) and creates two new UTXOs: one for 0.3 BTC locked to Charlie's public key and another for 0.2 BTC (minus fees) locked back to her own public key as change.
Common misconceptions
- UTXOs are account balances → Correction: UTXOs are not account balances; they are discrete outputs from transactions that must be spent in their entirety (with change returned).
- UTXOs are stored on-chain → Correction: UTXOs are not stored as separate entities on-chain; they are derived from the transaction history and validated during transaction processing.
Risks & limitations
- Transaction bloat: UTXO-based systems can accumulate many small UTXOs over time, leading to larger transaction sizes and higher fees if not managed.
- Dust attacks: Attackers can send tiny UTXOs to a user's address, clogging their wallet with unspendable outputs that increase transaction complexity.
- Privacy leaks: UTXO models can reveal transaction patterns if not used carefully, as inputs and outputs are publicly linked on the blockchain.