Merkle Leaf
Last Updated: November 19, 2026
A Merkle Leaf is the most basic unit in a Merkle Tree, representing an individual piece of data, like a single transaction, hashed and stored at the tree’s lowest level.
How It Works
Each Merkle Leaf holds a hashed version of data. Pairs of these are combined and hashed repeatedly, forming a structure that ends at a single Merkle Root, enabling quick and secure data verification.
A leaf stores a hash of the data rather than the data itself. A hash has a fixed size, 32 bytes for SHA-256, however large the input is, and changing even one bit of the input changes it completely. So any edit to a leaf changes every hash above it, up to the root.
Leaves in Bitcoin
In Bitcoin, each leaf is a transaction ID (TXID), a double SHA-256 hash of the transaction without its witness data. The coinbase transaction is always the first leaf. In block 976,170, mined on November 16, 2026, the first of 6,048 leaves is the coinbase ID starting 5912fbf1, and the last starts ed78f13d, according to mempool.space (read at 19:25 UTC).
Since SegWit, a second tree uses each transaction’s witness ID (wtxid) as a leaf, with the coinbase counted as all zeros. Its root is committed in an output of the coinbase transaction, as BIP 141 specifies.
Leaves in Proof of Reserves
In an exchange proof of reserves, each leaf stands for one client’s record. Kraken builds a leaf as the first 16 characters of a SHA-256 hash of a record ID plus the client’s balances, so clients can find their own entry without revealing who they are. That is the method on Kraken’s proof of reserves page, whose latest snapshot is dated September 30, 2026.
Why It’s Useful
Merkle Leaves allow blockchains to verify huge amounts of data with minimal processing, making systems more efficient and secure.
A Merkle proof starts from one leaf and climbs to the root, one sibling hash per level. In a block of 6,048 transactions that takes 13 hashes.
Limits
A leaf must never be confused with an inner node, and Bitcoin has a known edge case here. A transaction of exactly 64 bytes, without witness data, can be read either as a leaf or as two joined hashes, which could fool an SPV wallet.
Such transactions have been non-standard since 2019, and the Consensus Cleanup proposal, BIP 54, would make them invalid. On November 16, 2026, the BIP repository listed it as Complete, not Deployed.
Example: A Four-Leaf Tree
Take four transactions, A, B, C and D. Each becomes a leaf: H(A), H(B), H(C) and H(D). The next level hashes each pair, giving H(AB) and H(CD). The top level hashes those two into the root. To prove that C is included, a wallet needs only H(D) and H(AB), two hashes instead of the whole list.
When a level has an odd number of hashes, Bitcoin copies the last one and pairs it with itself. That rule caused a known bug, CVE-2012-2459, in which two different transaction lists could produce the same root. Other systems pad the tree or carry the odd node up unchanged, so leaf rules differ between projects.
Leaves Outside Blockchains
Merkle leaves are also used in Git, in Certificate Transparency logs and in file-sharing systems such as IPFS and BitTorrent v2. In each case, a leaf is the hash of one item, such as a file block or a certificate. Most of these systems use SHA-256 or a similar hash. A single changed item can then be found without checking everything again.
Frequently Asked Questions
What is a Merkle leaf in Bitcoin?
It is a transaction ID, the double SHA-256 hash of a transaction’s data without its witness. Every transaction in a block becomes one leaf, with the coinbase first. Block 976,170, mined on November 16, 2026, has 6,048 leaves, and pairing and hashing them level by level produces the Merkle root stored in the block header.
Are Merkle leaves the same in Bitcoin and Ethereum?
No. Bitcoin’s leaves are transaction IDs in a binary tree that is rebuilt for every block. Ethereum keeps accounts in a Merkle Patricia trie, where each account sits at a path derived from the hash of its address, and each block header carries the trie’s root. A draft proposal, EIP-7864, would move accounts, code and storage into one binary tree.
Can I find my own leaf in an exchange’s proof of reserves?
Yes, at exchanges that publish one. Kraken, for example, lets clients rebuild their leaf from a record ID and their balances, then follow the path of hashes to the published root. The leaf hides your identity behind a hash. It only shows that your balance was counted at the snapshot date, not what happened afterward.
Why are leaves hashed instead of storing the raw data?
A hash is short and fixed in size, 32 bytes for SHA-256, so the tree stays small however large each item is. Hashing also means a proof never has to reveal the other items in full. Any change to the underlying data changes its leaf hash, and that change carries up through every level to the root.
Data sources: mempool.space (block 976,170 transaction IDs, read 19:25 UTC, November 16, 2026), BIP 141 and BIP 54 in the Bitcoin BIPs repository (read November 16, 2026), Kraken proof of reserves page and EIP-7864 on eips.ethereum.org (read November 16, 2026).