BOMBARCHIVE
Explore

A living reference collection. Written in the wiki, preserved in Git.

The archiveBitcoin

Transaction replacement

Transaction replacement is the practice of replacing an unconfirmed Bitcoin transaction with a conflicting transaction, usually to offer miners a higher fee. It is a rule of mempool admission and relay policy, not a change to Bitcoin's rule that two confirmed transactions cannot spend the same output. Replacement appeared in the earliest client, was disabled in 2010, returned in a fee-based form in 2016, and became Bitcoin Core's default policy regardless of opt-in signalling in 2024. Bitcoin 0.1.5 source · 2010 disabling commit · Bitcoin Core 0.12.0 notes · Bitcoin Core 28.0 notes

The history is not simply a contest between a safe original Bitcoin and a later fee-market modification. The original replacement rule is directly preserved in source; its suspension is directly preserved in a dated change; and the later arguments over zero-confirmation payment acceptance concern different actors making decisions before a transaction enters a block.

2009: sequence-based replacement in the original client

The source tagged v0.1.5 contains a transaction-acceptance path that checks whether an input already conflicts with a transaction in the node's memory pool. Rather than rejecting all conflicts, it can identify an existing transaction, call IsNewerThan() to compare sequence-based versions, remove the old transaction and admit the replacement. The same original code limits the arrangement to a replacement spending the same collection of inputs. This is direct evidence of an implemented local acceptance rule, not evidence of a deployed payment-channel service. Bitcoin v0.1.5 — CTransaction::AcceptTransaction · Bitcoin v0.1.5 — transaction structures

The four-byte input field has a history of its own. Bitcoin sequence numbers separates sequence-based replacement in the earliest client, '''BIP 125's later replaceability signal** and BIP 68's consensus-enforced relative locktime. Notably, 0xfffffffe keeps transaction locktime available without opting in under the original BIP 125 threshold, whereas 0xfffffffd signals opt-in replacement while disabling BIP 68 relative delays. A sequence value is not, by itself, a guarantee about which unconfirmed transaction miners will confirm. BIP 68 · BIP 125

The nSequence fields, nLockTime and signature-hash options made it possible to imagine several parties repeatedly negotiating transaction state before settlement. The technique was distinct from a funded, two-party channel with a prepared refund: an unconfirmed transaction could be replaced through successive signed versions, but the network would eventually record only one winner. Bitcoin Wiki — design comparison

There is an unusually valuable testimony about intended use, but it must be dated correctly. On 17 April 2013, developer Mike Hearn publicly reproduced an explanation he attributed to an earlier private message from Satoshi Nakamoto. The text described a group signing successively higher-sequence transactions for high-frequency trades, with the final outcome broadcast when necessary. This is a contemporary first-party recollection and reproduced quotation published in 2013; the surviving mailing-list post does not establish when Nakamoto originally sent Hearn the message, and it is not an authenticated 2009 network demonstration. Hearn — Bitcoin-development mailing-list message, 17 April 2013

There was another change to the original fields before replacement was suspended. The v0.1.5 IsFinal() method interpreted nLockTime as a block height; a **29 October 2009''' source diff added the 500,000,000 timestamp threshold and a scheduled block-validation check. Replacement's nSequence history and the locktime rules were related, but they were not the same mechanism. Their later reuse in BIP 68 and CSV is followed in Bitcoin timelocks. Original finality function · October 2009 source diff · BIP 68

19 August 2010: the feature is actually switched off

This change can be pinned more precisely than the shorthand “removed in Bitcoin 0.3.12”.

Imported Subversion revision trunk@140, preserved as Bitcoin commit 05454818dc7e, was committed on 19 August 2010 at 22:43:19 UTC. In the transaction-conflict branch, it inserts an unconditional return false; immediately after the comment “Disable replacement feature for now”. The prior sequence-comparison implementation remains below that line but becomes unreachable for that path. The change is visible in the exact commit diff, not inferred from later release notes. Bitcoin source — dated implementation change

The commit's general message concerns block-index checks, redundant validation and refactoring. It does not itself offer a written security rationale for the replacement-specific line. Later developers explain that fee-free replacement could waste relay bandwidth and that miners had no economic reason to privilege higher sequence numbers; those explanations are supported by later first-party specifications, not by a claim that the short 2010 comment fully explained the decision. BIP 125 — motivation and retrospective description

Bitcoin 0.3.12 subsequently carried this behavior. The release number and the direct 19 August source-commit date denote different historical events. Neither should be silently substituted for the other. Bitcoin v0.3.12 — surviving rejection path

2013: revisiting replacement, cautiously

The discussion did not vanish with the old code. An April 2013 Bitcoin-development thread debated anti-denial-of-service rules for replacement. Hearn's publication of Nakamoto's proposed high-frequency negotiation belonged to that discussion. It establishes a remembered use case and an engineering debate, not a reversal of the 2010 production policy. Hearn, 17 April 2013

On 9 May 2013, John Dillon announced a testnet implementation developed with Peter Todd and linked Todd's replace-by-fee source branch. The announcement explicitly said its fee-evaluation work was incomplete, acknowledged a remaining denial-of-service vulnerability, and advised against mining on mainnet with the prototype. The proposed testnet server allowed wallet developers to try conflicting transactions. Those qualifications matter: this was an announced experimental implementation, not the later Bitcoin Core default. Dillon — dated first-party testnet announcement

Over the ensuing debate, two partly competing objectives became explicit. Spenders wanted a practical way to raise fees on slow unconfirmed transactions. Recipients accepting zero-confirmation payments wanted some indication that a transaction they had already observed would not disappear. A proposed first-seen-safe approach constrained replacements to preserve earlier payment outputs, at the cost of adding inputs, increasing transaction size and potentially harming privacy. These positions and the technical trade-offs are recorded in BIP 125's authors' later account; that account should not be mistaken for a universally agreed contemporary verdict on the dispute. Harding and Todd — BIP 125, motivation

December 2015–February 2016: opt-in replace-by-fee

BIP 125, by David A. Harding and Peter Todd, was assigned on 4 December 2015. It specifies a mempool policy under which an input with nSequence below 0xfffffffe explicitly signals replaceability. An unconfirmed descendant can also inherit that status from a replaceable ancestor. The distinction between a sender's signal and a node's actual policy is essential: signalling did not make a replacement compulsory for every node or miner. BIP 125 — specification

The original policy also placed constraints on replacements: the total fee had to cover that of displaced transactions and pay for additional relay bandwidth; new unconfirmed inputs were restricted; and the number of evicted transactions, including descendants, was bounded. These were controls on mempool churn and incentive compatibility, not new consensus-validity rules. The historical BIP is not a complete statement of every later Core policy revision. BIP 125 — original implementation rules

Bitcoin Core 0.12.0, released 23 February 2016, introduced opt-in replacement support for nodes. Its release notes warned that disabling replacement locally did not prevent other nodes from relaying or mining an opted-in conflicting version. This was a specific software release milestone, not proof that every wallet immediately supported fee bumping or that every miner adopted the policy. Bitcoin Core 0.12.0 release record · Bitcoin Core release announcement

2022–2025: from signalling to default full replacement

A later sequence of Bitcoin Core releases records a decisive change, but in node policy, not consensus:

  • 24.0.1 (2022): introduced mempoolfullrbf, a configuration option to accept replacements even when the original had not signalled under BIP 125. It defaulted to off. The release notes explicitly distinguished the first-seen expectation used by some services from any assurance the Bitcoin protocol could make. Versioned release notes
  • 28.0 (October 2024): switched the mempoolfullrbf default from 0 to 1. This expanded default relay acceptance of higher-fee conflicts; it did not remove the other resource and fee controls on replacement. Versioned release notes
  • 29.0 (April 2025): removed the mempoolfullrbf option, citing widespread adoption and little remaining benefit to disabling it. Full replacement thereby became the standard behavior of that Bitcoin Core release. Other node implementations and miners still have their own policies. Versioned release notes

Relation to payment channels, fees and application indexes

Bitcoin payment channels use successive signed states so participants can conduct multiple payments without immediately recording each update in a block. Nakamoto's early notion of revisable unconfirmed transactions is part of that design ancestry; 2016-and-later RBF is not itself a payment channel. RBF manages which conflicting candidate settlement transaction a node retains or relays. Modern channels rely on other mechanisms to enforce agreed state and handle unilateral closes. Bitcoin Wiki — distinct channel designs · Lightning specifications

Another technique, child-pays-for-parent (CPFP), does not replace the parent's transaction at all: a descendant offers fees that incentivize a miner to confirm both. Confusing CPFP with RBF conceals why wallet authors must track which transaction identifiers and unconfirmed outputs remain usable. Bitcoin Core 28.0 — package relay, replacement and anchors

For Ordinals and Bitmap, the operational implication is straightforward but should not be inflated into a separate consensus rule. A pending reveal or claim is not a stable chain fact merely because an indexer has seen it in a mempool. A conflicting transaction may be mined instead, or no candidate may confirm. Claim eligibility, ordering and references must ultimately be reconstructed from the confirmed Bitcoin chain under the relevant application's rules. That is an architectural inference from Bitcoin's transaction-selection boundary, not evidence that all indexers have implemented one particular mempool policy.

From the archivist's desk

The detail that caught my attention was the line left in the 2010 code: the old replacement machinery still appears immediately after the unconditional rejection. It was not a forgotten idea rediscovered from nothing six years later. The mechanism, the threats, the incentives and the users' expectations changed around a surviving seam.

One lesson runs from the 2010 source to present-day indexing: '''a candidate transaction can be observable without being part of Bitcoin's history'''. Before confirmation it is a proposal the network may revise. The archive should name proposals as proposals, even when the software presents them vividly.

Open question
Recover the earliest original-release source archive and test the 2009 sequence-replacement code in an isolated historical environment; source presence does not establish reliable multi-party trading.
Open question
Locate the original dated private Satoshi–Mike Hearn correspondence, if lawfully preserved, rather than assigning a date from Hearn's 17 April 2013 public reproduction.
Open question
Preserve representative 2013 replacement-test logs or transactions and version-specific later policy tests, rather than extrapolating actual uptake from proposals and release notes.