Bitcoin nodes follow the valid chain with the most accumulated proof of work, not the chain with the most blocks: Bitcoin Core ranks candidate chain tips first by total chain work, so a shorter chain of harder blocks can outrank a longer chain of easier ones.
Sources and checks
T1Bitcoin Core src/node/blockstorage.cpp, CBlockIndexWorkComparatorSource code, says this directly
if (pa->nChainWork > pb->nChainWork) return false;
CBlockIndexWorkComparator::operator(), read 2026-11-20
T1Bitcoin Core src/chain.h, CBlockIndex::nChainWorkSource code, says this directly
Total amount of work (expected number of hashes) in the chain up to and including this block
CBlockIndex, nChainWork member comment, read 2026-11-20
T2Bitcoin: A Peer-to-Peer Electronic Cash SystemPaper, supports part of it
The majority decision is represented by the longest chain, which has the greatest proof-of-work effort invested in it.
Section 4, Proof-of-Work, third paragraph, read 2026-11-20
bitcoin/bitcoin at f498a5a671 contains this text in src/node/blockstorage.cpp, and still does on the default branch.
Run it yourself
git clone https://github.com/bitcoin/bitcoin && git -C bitcoin show f498a5a6718d9157b6afb85412c3462439117702:src/node/blockstorage.cpp | grep -nF 'if (pa->nChainWork > pb->nChainWork) return false;'Checked at block 976,753, 20 Nov 2026, 16:42 UTC: quotes 3/3, code 1/1
History
Nothing is edited silently; every revision keeps what it replaced.
- 20 Nov 2026, 16:42 UTCblock 976,753
Published Revision 1, run 2026-11-20-seed-proof-of-work