Does Bitcoin Always Follow the Longest Blockchain?
No. The phrase "longest chain" is a common shorthand, but Bitcoin's relevant selection rule is the valid chain with the greatest accumulated proof of work, not simply the greatest number of blocks.
Why is block count insufficient?
Different difficulty targets imply different amounts of expected work per block. A chain's cumulative work therefore cannot be determined from its height alone.
Can an invalid chain win by adding more work?
No. A fully validating node rejects blocks that violate consensus rules. A higher-work chain containing invalid blocks is not an acceptable active chain for that node.
What happens during a reorganization?
If a competing valid branch has more accumulated work, a node can switch its active chain to that branch. Transactions in disconnected blocks may lose confirmations, so applications should account for reorganization risk.
Primary references
Bitcoin Developer Guide — Block Chain: https://developer.bitcoin.org/devguide/block_chain.html
Bitcoin whitepaper: https://bitcoin.org/bitcoin.pdf
