Home › Glossary › Consensus rules

Consensus rules

Also called: consensus, validation rules, consensus layer, consensus vs policy.

Consensus rules are the checks every full node applies to decide whether a block or transaction is valid; a block that breaks one is rejected.

Consensus rules are the checks every full node applies to every block and transaction. A block that breaks one is invalid, no matter how much work went into it, and nodes refuse to build on it. Because all nodes apply the same rules independently, they agree on one chain without trusting each other.

Examples of consensus rules

Consensus vs policy

Nodes also apply policy (or "standardness") rules, such as minimum relay fees, dust limits and replace-by-fee rules, to decide which unconfirmed transactions enter their mempool and get relayed. Policy is local and each operator can change it. A non-standard transaction is still valid if a miner puts it in a block. Consensus rules, by contrast, must match on every node, or the network splits.

Changing consensus rules

Tightening the rules is a soft fork; loosening them is a hard fork. BIP 99 describes both. Deployed changes are listed under deployed BIPs, and BIP 90 shows how old activation logic was later replaced by fixed block heights.

There is no separate written specification: the rules are whatever widely used node software enforces. BIP 50 shows the risk, describing how an undocumented database limit in 2013 implicitly became a consensus rule and split the chain.

BIPs that define Consensus rules

  • BIP 99: Motivation and deployment of consensus rule changes ([soft/hard]forks): Closed. Lays out a classification of the different ways Bitcoin's core rules can be changed, such as soft forks and hard forks, and explains the reasons behind each. It also recommends how each type should…
  • BIP 141 (SegWit): Segregated Witness (Consensus layer): Deployed. Defines Segregated Witness (SegWit), which moves signatures into a separate "witness" section of each transaction while remaining compatible with older nodes. This fixed transaction malleability,…
  • BIP 90: Buried Deployments: Deployed. Simplifies how Bitcoin software enforces three older soft forks (BIP 34, 65 and 66) by hard-coding the block heights at which they took effect, instead of re-checking how miners voted. Since those…
  • BIP 50: March 2013 Chain Fork Post-Mortem: Deployed. A post-mortem of the March 2013 incident in which a database limit in older Bitcoin software caused the blockchain to split temporarily. It explains what went wrong, how miners and developers…

Related terms

  • Soft fork: A soft fork is a backward-compatible change to Bitcoin's consensus rules that only tightens them, so old nodes still accept the new blocks.
  • Hard fork: A hard fork is a change to Bitcoin's consensus rules that makes previously invalid blocks valid, so nodes that don't upgrade split off the chain.
  • Node: A Bitcoin node is a computer running Bitcoin software that downloads, checks and relays blocks and transactions; a full node verifies every rule itself.
  • Mempool: The mempool is a node's waiting area for valid, unconfirmed transactions; miners choose from it, usually by fee rate, when they build a block.

Learn more

Guides