— —
Follow on X
LESSONS

Nodes, consensus and the longest chain

Full nodes verify every rule and reject anything invalid, no matter how much work is behind it. The valid chain with the most work wins.

6 MIN READ
A proposed block is checked by every node and accepted or dropped.
LEVEL · Intermediate
IN THIS LESSON · 7 OF 9
BY THE END YOU WILL BE ABLE TO ANSWER
  • A miner builds a block paying itself 10 BTC subsidy. What happens?
  • Which chain do nodes follow?
  • Who activated SegWit in 2017?
  • Which of these does a node reject even with all the hash power behind it: (1) a block with an invalid signature, (2) a block paying a 7 BTC subsidy, (3) both? Enter the number.

Then prove it: a 3-question quiz · a challenge. The lesson marks itself complete at 100%.

After this lesson you can: say what a node rejects and why miners cannot override it.

A full node downloads every block and checks every transaction against the consensus rules: valid signatures, no double spends, correct subsidy, hash below target, size limits, script rules. Anyone can run one on a modest computer. Tens of thousands do.

Miners propose, nodes dispose

A block with an invalid transaction is rejected by nodes however much work it contains. The miner wasted its electricity. This is why miners cannot change the rules: a block paying a 50 BTC subsidy today would be ignored by every node, and so by every other miner. Hash power decides the order of valid blocks; it does not decide what valid means.

A miner proposes a block; every node checks it independently and rejects an invalid one.
Hash power orders valid blocks. Nodes decide what valid means.

Forks in the chain

Two miners sometimes find blocks seconds apart. Nodes keep both until one is extended, then follow the valid chain with the most accumulated work and discard the other (a reorganisation). This is why six confirmations is a common standard: a six-deep reorg against honest miners is practically impossible.

Two blocks found at the same height; the one that is built on wins and the other is orphaned.
A natural fork. Nodes keep both candidates until one chain gets more work behind it.

Changing the rules

Two columns comparing soft forks and hard forks.
Soft forks tighten, hard forks loosen. Almost all of Bitcoin’s upgrades have been soft forks.

Because every node enforces the rules it chose to run, changing them requires node operators to agree to upgrade. Soft forks tighten rules and stay compatible with old nodes; hard forks loosen them and split anyone who does not upgrade onto a different chain. Bitcoin's history is almost entirely soft forks, which is why its rules change slowly and rarely. The 2017 SegWit activation was forced by users running nodes, over the objection of most miners: the clearest demonstration of where power lies.

How the Bitcoin network works · RiverWatch on YouTube ↗
MINI CHALLENGECount the rules

Which of these does a node reject even with all the hash power behind it: (1) a block with an invalid signature, (2) a block paying a 7 BTC subsidy, (3) both? Enter the number.

CHECK YOURSELF
1/3 A miner builds a block paying itself 10 BTC subsidy. What happens?
2/3 Which chain do nodes follow?
3/3 Who activated SegWit in 2017?
pick an answer for each question

SOURCES

  1. Bitcoin: A Peer-to-Peer Electronic Cash System (Satoshi Nakamoto, 2008)
Progress is saved in this browser only.