← Glossary

Wallet basics

What Is Replace-by-Fee (RBF)? Speeding Up a Stuck Transaction

Replace-by-fee (RBF) is a policy that lets a sender replace an unconfirmed transaction in the mempool with a new one spending the same coins and paying a higher fee, as specified for Bitcoin Core in BIP-125.

Key takeaways

The problem it solves

A transaction sent with too low a fee can sit unconfirmed for a long time while miners take better-paying ones. If you cannot cancel it, your coins stay in limbo. Replace-by-fee gives the sender a way out: broadcast a new version of the same transaction with a higher fee, and nodes that follow the policy swap it in.

How BIP-125 works

BIP-125 describes opt-in signalling. A transaction signals that it can be replaced when any of its inputs has an nSequence value below 0xffffffff − 1. A transaction that does not signal, and whose unconfirmed ancestors do not signal either, is not replaceable under this policy. The BIP lists the conditions for replacement, including that the new transaction pays an absolute fee at least equal to the sum of those it replaces, plus enough extra to cover its own relay cost, and that no more than 100 transactions are evicted.

Risks for the receiver

Because a signalling transaction can be replaced, the recipient can be paid by one version that is later swapped for another, perhaps sending the coins elsewhere. The BIP therefore recommends that recipients of a replaceable transaction do not treat it as payment until it is confirmed. If you accept payments, wait for confirmation of anything that signals replaceability.

What to do as a sender

If your wallet supports it, use its fee-bump function rather than building the replacement yourself. Bumping works only while the original is unconfirmed and replaceable, and it uses the same inputs, so you are not sending a second payment. If your wallet does not support it, wait; many unconfirmed transactions are eventually mined as congestion eases or dropped.

Example

You send 1 coin at 1 satoshi per byte and it stalls. Your wallet creates a new transaction spending the same inputs to the same recipient at 5 satoshis per byte. Nodes replace the original with it, and a miner includes the higher-paying version.

Put it into practice

Check before you rely on unconfirmed funds

A pending payment can change until it confirms. Scrypt Wallet lets you pick a block explorer so you can see whether a payment has confirmed before you act on it.

Create a free wallet Get Scrypt for Android

Sources and verification

Last reviewed 2026-10-02 by the Scrypt Wallet team. The factual claims on this page, and where each comes from:

  1. A transaction explicitly signals replaceability if any input has an nSequence number less than 0xffffffff − 1. [1]
  2. The replacement must pay an absolute fee at least equal to the sum of the transactions it replaces, and the number of evicted transactions must not exceed 100. [1]
  3. Recipients of a replaceable transaction may choose not to treat it as payment until it is confirmed. [1]

Sources

  1. BIP-125: Opt-in full replace-by-fee signaling · bitcoin/bips on GitHub · primary source

Primary sources are protocol papers, specifications, source code or a project's own documentation; secondary sources are wikis and explainers. We checked each claim against the source text on the review date. Found an error? Tell us and we will correct it.

Frequently asked questions

Is RBF part of the consensus rules?

No. It is a node policy for which unconfirmed transactions to keep, so different nodes and different coins can behave differently.

Can I cancel a transaction with RBF?

A replacement can send the same coins elsewhere, such as back to yourself, if the original was replaceable and is still unconfirmed.

Is an unconfirmed payment safe to accept?

Not if it is replaceable. Wait for confirmation, because the replacement could redirect the coins.

Related terms

Go deeper

Written by the Scrypt Wallet team · Updated 2026-10-02. General education, not financial, tax or legal advice.