MSTR Cat

Blockchain/Level IV · Protocol depth/4.1 Script/Lesson 6

Standardness and policy

The difference between what the network accepts and what your node relays

MaterialsBitcoin Core source code (policy/policy.cpp)Bitcoin Optech’s ‘Waiting for confirmation’ seriesA block explorer that shows raw scripts

Wonder

  1. Why does a valid transaction sometimes get rejected by a wallet before it ever reaches a miner?
  2. What happens if a counterparty runs different software than you do, but both are ‘correct’?
  3. How can keeping unused opcodes off the relay path protect future upgrades?

Explore

  1. Consensus rules define validity; they determine what may appear in a block and be accepted by every node. Standardness is a separate, local policy that dictates which transactions a specific node relays to its peers and keeps in its memory pool. A transaction can be perfectly valid under consensus yet non-standard according to default relay policies. When a user broadcasts such a transaction, their own node may discard it immediately, even though miners could technically include it.
  2. Standard output types are strictly limited to protect nodes from denial-of-service attacks and resource exhaustion. These include P2PKH, P2SH, P2WPKH, P2WSH, P2TR, small bare multisig scripts (up to three keys), and OP_RETURN data outputs of a specific size. Scripts using reserved or unknown opcodes, or exceeding size limits, are not relayed by default. This filtering ensures the mempool remains manageable and prevents malicious actors from flooding the network with complex, computationally expensive garbage.
  3. Policy is not static; it evolves per node implementation. In 2025, Bitcoin Core developers decided to relax the default size limit on OP_RETURN data outputs. This change sparked debate among node operators, some of whom opposed the expansion and switched to alternative software like Bitcoin Knots to maintain stricter legacy limits. This divergence illustrates that standardness is a local setting: two nodes running different versions or forks can relay different subsets of valid transactions without violating consensus.
  4. A non-standard but valid transaction can still be confirmed if it bypasses the default relay network entirely. Miners have offered direct submission services, allowing users to send transactions straight into their blocks regardless of node policy. If a wallet relies on standardness rejection for security—assuming an invalid-looking script will never propagate—it faces a risk: a counterparty using direct miner access could confirm that transaction. This creates a fork in behavior, not truth, potentially leading to unexpected fund movements or loss.
  5. Standardness acts as a safety valve for future soft-fork upgrades. By enforcing stricter rules now—such as treating reserved upgradable NOP opcodes as non-standard during relay—the protocol ensures a smooth transition when an upgrade tightens consensus rules. Because transactions that use the reserved opcodes are not relayed or mined by default, few or none exist when a soft fork gives those opcodes meaning, so the new rules invalidate nothing that people were relying on, and un-upgraded miners are unlikely to mine a block the new rules reject.
  6. Read the policy checks yourself: in Bitcoin Core’s source, policy/policy.cpp contains IsStandard and IsStandardTx, which list the accepted output types and size limits; Bitcoin Optech’s ‘Waiting for confirmation’ series explains the reasoning behind them. Compare them with the consensus rules in validation code, and note how much narrower the relay rules are.

Key facts

  • Consensus rules define validity; standardness defines relay behavior.
  • Standard output types include P2PKH, P2SH, P2WPKH, P2WSH, P2TR, and small bare multisig.
  • Policy protects nodes from denial-of-service by filtering complex or large scripts.
  • Non-standard transactions can be confirmed via direct miner submission services.
  • Bitcoin Core relaxed OP_RETURN size limits in 2025, prompting some users to switch software.
  • Standardness filters reserved opcodes to facilitate future soft-fork upgrades.

Exercise nine, six, three, one

9CollectList 9 different output script types or formats used in Bitcoin history. For each, note whether it is currently considered standard by default node policies.
6ClusterGroup the 9 into 6 categories based on their structural complexity: simple key hashes, wrapped scripts, native witness, complex multi-party, data embedding, and legacy/experimental.
3DistillReduce the 6 groups to 3 core reasons why nodes impose standardness limits on these specific structures.
1CrystallizeWrite 1 sentence explaining how local policy divergence can lead to consensus-valid but relay-invalid transactions propagating directly to miners.

Fact check

Dates, figures and claims checked against the published sources listed below.

Open in the interactive academy →

PT ES ZH JA KO RU DE FR MS