TECHNICAL_DOC // BLOCKCHAIN / UTXO-SET
UTXO SET
The utxo-set/">UTXO set is the complete database of all unspent transaction outputs in
existence. It represents the current state of Bitcoin ownership. Every node/">full node maintains
this set in memory (RAM) for instant validation. When a new block arrives, spent UTXOs are
removed and newly created outputs are added — the set evolves with every block.
UTXO_SET_STRUCTURE
WHAT EACH UTXO ENTRY CONTAINS
Key: TxID (32 bytes) + Vout index (4 bytes)
Value: {
amount: satoshis (8 bytes)
script_pubkey: locking script (variable)
height: block height when created (4 bytes)
is_coinbase: bool (for coinbase maturity checks)
}
Example entry:
Key: a1b2c3...ff:0
Value: { amount: 50000000, script: 76a914...88ac, height: 840123 }
STORED IN
BITCOIN CORE STORAGE — chainstate/
Database: LevelDB (key-value store, highly optimized)
Location: ~/.bitcoin/chainstate/
Format: Obfuscated (XOR key applied to prevent false virus alerts)
In RAM: ~6 GB for full UTXO set (2024, ~87M entries)
On disk: ~10 GB (LevelDB compressed)
Loaded into RAM on startup via dbcache setting
-dbcache=6000 (MB) recommended for full UTXO set in memory
UTXO_SET_LIFECYCLE
Block Processing — UTXO Changes
PER BLOCK
Every block modifies the UTXO set in a specific order. Bitcoin Core processes all transactions in a block atomically — either all changes apply or none do.
For each transaction in block (except coinbase):
1. For each INPUT:
Remove UTXO(txid, vout) from set ← coins destroyed
2. For each OUTPUT:
Add UTXO(new_txid, index, amount, script) to set ← coins created
For coinbase transaction:
1. No inputs to remove
2. Add coinbase outputs to set (unspendable for 100 blocks)
Net effect: sum of destroyed == sum of created + miner fee
KEY_STATISTICS_2024
Total UTXO entries~87 million
RAM required (full set)~6 GB
Disk size (LevelDB)~10 GB
Total BTC in UTXO set~19.7 million BTC
Estimated lost BTC (unspendable)~3–4 million BTC
Average UTXO value~0.23 BTC (~$23K @ $100k)
UTXO Bloat
SCALING CONCERN
Every output/">unspent output must live in every full node's UTXO set forever. Dust outputs (too small to spend economically) permanently bloat the set.
Dust threshold (P2PKH): ~546 satoshis
= minimum output value where spending costs more in fees than the output value
Solutions:
→ Dust relay filter: nodes reject txs creating dust outputs
→ Consolidation: users merge many UTXOs into fewer larger ones
→ OP_RETURN: data outputs are unspendable → pruned from UTXO set
→ Taproot: more efficient scripts → smaller UTXO entries
TERMINOLOGY_INDEX
UTXO Set
The complete database of all unspent outputs. Every full node maintains this to validate transactions.
chainstate
Bitcoin Core's directory containing the LevelDB UTXO database and block index.
LevelDB
A key-value store library used by Bitcoin Core to persist the UTXO set on disk.
Dust
A UTXO whose value is less than the fee required to spend it. Creates permanent UTXO set bloat.
dbcache
Bitcoin Core config parameter controlling how much RAM is allocated for the UTXO cache.
AssumeUTXO
A Bitcoin Core optimization that bootstraps a node using a trusted UTXO snapshot, avoiding full IBD.
INTERACTIVE — TRY IT YOURSELF
TRANSACTIONS / CONSENSUS
UTXO Set
Bitcoin has no "account balances." Instead, every wallet's balance is the sum of its Unspent Transaction Outputs (UTXOs). Spending bitcoin means selecting UTXOs as inputs and creating new outputs — the selected inputs are destroyed and new UTXOs are born. Every full node maintains a complete UTXO set in memory (~10 GB as of 2024) for fast validation.
LIVE UTXO SET SIMULATOR
Click UTXOs to select them as inputs for a new transaction. Add recipient outputs. When you broadcast, the selected UTXOs are consumed and new ones created — just like real Bitcoin mempool flow.
UTXO SET — CLICK TO SELECT AS INPUTselect inputs then build tx
TRANSACTION BUILDER
BUILD & BROADCAST TRANSACTIONselect UTXOs above first
INPUTS (selected UTXOs)
No inputs selected. Click UTXOs above.
OUTPUT — RECIPIENT
sats
UTXO vs Account model: Ethereum uses account balances (like a bank). Bitcoin uses UTXOs. UTXO is more private (each transaction can use fresh addresses), more parallelizable for validation, and enables SPV proofs. The downside: wallets must track individual coin fragments, and consolidating many UTXOs requires larger transactions.