Two miners find a valid block at nearly the same instant. Half the network sees one first, half sees the other — for a moment, there are two "true" histories. How does the network converge back to one, and when can you actually trust a block won't be undone?
Chain A is canonical right now — it simply has more blocks.
Extend either chain and watch the "canonical" tag jump to whichever fork is longer. There's no vote, no authority deciding — the rule is mechanical: more blocks wins, full stop. A fork that falls behind doesn't get argued away; it just stops being extended, because no rational miner keeps building on the losing side.
- A fork is just two chains sharing a prefix
Both Chain A and Chain B in this chapter start from the same genesis block, then diverge — each new block hashes in the previous block's hash, so a fork is nothing more than two different sequences of blocks after the split point.
- The longest chain is canonical
(ties have no winner yet). Real chains compare cumulative proof-of-work, not raw block count, but with one difficulty target shared by everyone, the two are the same thing.
- Finality is a probability, not a guarantee
A block already has confirmations once further blocks are built on top of it. An attacker controlling a fraction of the network's power can still try to grow a secret, longer fork in secret and replace it — but the odds fall off fast as grows.
- The reversal probability shrinks exponentially in confirmations
— every additional confirmation multiplies the attacker's chances by the same ratio , which is less than 1 whenever the attacker controls a minority () of the network.
- — confirmations: how many blocks are stacked on top of the one in question.
- — the attacker's share of total mining power; is the ratio the probability shrinks by per confirmation.
Drag right to add confirmations. With an attacker holding 20% of the network's power, each additional confirmation multiplies their odds of catching up by another factor of 0.25 — finality is never absolute, just increasingly unlikely to fail.
Drag along the curve to add confirmations and watch the reversal probability collapse. This is why "wait for N confirmations" is a real, if informal, security parameter: N isn't chosen because reversal becomes impossible, but because it becomes vanishingly, practically impossible.
Chain A: 3 blocks (a1→216, a2→14, a3→883). Chain B: 2 blocks (b1→247, b2→399). Attacker share
.
- Which chain is canonical right now
, so Chain A is canonical — even though Chain B's blocks are individually just as validly hashed.
- Chain B catches up and passes
If Chain B mines two more blocks (length 4), the rule flips: means Chain B is now canonical, and every honest node that was building on Chain A discards those blocks and switches.
- Reversal probability at z = 2 confirmations
— a 1-in-16 chance the attacker still catches up, still too risky to treat as final.
- Reversal probability at z = 3 confirmations
— this is the first depth where the probability drops under this chapter's finality threshold of . Two confirmations weren't enough; three are.
Slide to the minimum number of confirmations (0–10) that pushes the reversal probability strictly under 0.02.
A fork resolves the moment one side pulls ahead in length — no vote required, just miners rationally building on whichever chain is winning. "Finality" is the point where reversing a block has become so improbable that treating it as permanent is a safe bet, not a mathematical certainty. Everything so far has assumed honest majority mining; the next chapters look at what a network built entirely out of code — smart contracts — does once that consensus object is settled.