TeachMeBitcoin

What is the UTXO Model

From TeachMeBitcoin, the free encyclopedia ⏱️ 4 min read

What is the UTXO Model? (Unspent Transaction Outputs)

When you look at your traditional bank account, you see a single number representing your balance. If you have $100 and receive $50, your balance mutates to $150. This is known as an Account-Based Model.

Bitcoin does not work this way. Bitcoin operates on the UTXO (Unspent Transaction Output) Model. In Bitcoin, there is no such thing as an "account balance" at the protocol level.


πŸ›οΈ Account-Based vs. UTXO-Based Ledgers

To understand the difference, consider how traditional banks and Bitcoin handle money:

1. The Account Model (Banks, Credit Cards, Ethereum)

Think of your bank account as a digital whiteboard. * If Alice wants to send Bob $20: 1. The bank checks if Alice's balance is $\ge \$20$. 2. The bank subtracts $20 from Alice's account. 3. The bank adds $20 to Bob's account. * Key Characteristic: Balances are mutable, single-state numbers.

2. The UTXO Model (Bitcoin)

Think of Bitcoin as a physical leather wallet filled with paper cash bills and metal coins of different denominations (e.g., a $5 bill, a $10 bill, and a $20 bill). * You do not have a single "balance." Instead, you have a collection of discrete, indivisible units of currency of varying sizes. * Each of these individual paper bills is an Unspent Transaction Output (UTXO). * Key Characteristic: UTXOs are immutable, atomic, and indivisible. You cannot spend "half" of a UTXOβ€”you must spend the entire UTXO and receive change.

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                   ACCOUNT LEDGER                       β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Alice Balance: $100        β”‚ Bob Balance: $50          β”‚
β”‚          └─(-$20)───┐      β”‚          β–²                β”‚
β”‚                     β–Ό      β”‚          β”‚(+$20)          β”‚
β”‚ Alice Balance: $80  β””β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜                β”‚
β”‚                            β”‚ Bob Balance: $70          β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                    UTXO LEDGER                         β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Alice's Wallet:            β”‚ Bob's Wallet:             β”‚
β”‚  [UTXO 1: 0.5 BTC]         β”‚  [UTXO 3: 0.1 BTC]        β”‚
β”‚  [UTXO 2: 0.8 BTC]         β”‚                           β”‚
β”‚                            β”‚                           β”‚
β”‚ Alice spends [UTXO 1] ───► β”‚ Creates brand new outputs:β”‚
β”‚ (Indivisible)              β”‚  [UTXO 4: 0.2 BTC] (Bob)  β”‚
β”‚                            β”‚  [UTXO 5: 0.3 BTC] (Alice)β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

πŸ”„ The Lifecycle of a UTXO

Every satoshi in existence belongs to exactly one UTXO. The lifecycle of any UTXO is simple and linear:

     Creation                    Validation                     Destruction
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”         β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”         β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                 β”‚         β”‚   Registered in   β”‚         β”‚                   β”‚
β”‚ Mined as Reward │────────►│ Global UTXO Set   │────────►│ Consumed as Input β”‚
β”‚  or Sent in Tx  β”‚         β”‚  (RAM Database)   β”‚         β”‚   in New Spend    β”‚
β”‚                 β”‚         β”‚                   β”‚         β”‚                   β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜         β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜         β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
  1. Creation: A UTXO is created as an Output of a transaction. Once written to the blockchain, it is registered in the global unspent database.
  2. State of Rest: The UTXO sits completely untouched on the ledger. It cannot be mutated, edited, or partially spent.
  3. Destruction: To spend these coins, the UTXO is consumed as an Input in a new transaction. The moment the spending transaction is confirmed, that original UTXO is permanently destroyed and removed from the active set, and brand new UTXOs are created in its place.

πŸ›‘οΈ Why Bitcoin Uses the UTXO Model

The UTXO model is more complex than an account model, but it offers massive structural advantages:

β˜• Help support TeachMeBitcoin

TeachMeBitcoin is an ad-free, open-source educational repository curated by a passionate team of Bitcoin researchers and educators for public benefit. If you found our articles helpful, please consider supporting our hosting and ongoing content updates with a clean donation:

Ethereum: 0x578417C51783663D8A6A811B3544E1f779D39A85
Bitcoin: bc1q77k9e95rn669kpzyjr8ke9w95zhk7pa5s63qzz
Solana: 4ycT2ayqeMucixj3wS8Ay8Tq9NRDYRPKYbj3UGESyQ4J
Address copied to clipboard!