What Is Replace-By-Fee (RBF) in Bitcoin?

What is Replace-By-Fee?
Replace-By-Fee, usually shortened to RBF, is a Bitcoin feature that lets someone replace an unconfirmed transaction sitting in the mempool with a new version of the same transaction that pays a higher fee — most commonly used to speed up a payment sent with too low a fee to confirm in a reasonable time.
Why would anyone need this? Because Bitcoin fees are a bidding market, and it’s easy to misjudge how much fee a transaction needs during busy periods. Without RBF, sending a transaction with too low a fee meant it could get stuck in the mempool for hours or days, with no way to fix it except waiting it out.
How does it actually work? When creating a transaction, a wallet can mark it as RBF-enabled. If that original transaction hasn’t confirmed yet, the sender can broadcast a new version — same inputs, same recipient and amount, but a higher fee — and miners will generally prefer the higher-fee version since mempool transactions aren’t final until mined.
Is there a downside? RBF technically allows the sender to change the transaction before it confirms, which in theory could be used to attempt something resembling a double-spend against a merchant who accepted a zero-confirmation payment as final. This is why many merchants wait for at least one confirmation, or flag RBF-signaled transactions with extra caution.
For ordinary users, RBF is mostly a convenience feature — a safety valve for fixing an underpaid fee without needing to wait indefinitely, available in most modern Bitcoin wallets as a simple toggle when sending a transaction.
Curious what happens to a transaction that never gets confirmed at all? Continue learning in the Bitcoin Academy.
