Fee Rate
When miners select transactions for inclusion in a block, they don't just look at the raw fee amount, they evaluate transactions based on their fee rate.
This is how we calculate the fee rate:
Miners use the fee rate to maximize their profit by comparing the profitability of including different transactions in their blocks.
For example, consider these two transactions:
- Transaction A: 50,000 sats fee, 250 vbytes size
- Transaction B: 30,000 sats fee, 100 vbytes size
Fee Rates:
- Transaction A: 200 sats/vbyte (50,000 ÷ 250)
- Transaction B: 300 sats/vbyte (30,000 ÷ 100)
Fee Rate Priority
Even though Transaction A pays a higher absolute fee, Transaction B is more profitable for miners because it provides more fees per unit of block space.
Fee Rate Units
There are three common ways to measure fee rates:
- sats/vbyte (Most Common)
- sats/wu (Internal)
- sats/byte (Legacy)
Unit | Description | Usage | Example |
---|---|---|---|
sats/vbyte | Virtual bytes account for witness discount | Most common unit used by wallets and block explorers | 50 sats/vbyte |
sats/wu | Weight units used internally by Bitcoin Core | Internal Bitcoin Core (4M WU block limit) | 12.5 sats/wu |
sats/byte | Deprecated since SegWit activation | Legacy software only | 50 sats/byte |
Understanding Virtual Bytes (vBytes)
Virtual bytes (vBytes) are a way to express transaction size that accounts for the SegWit discount. The formula is simple:
Transaction Type | Weight Units | Virtual Bytes |
---|---|---|
Legacy (non-SegWit) | size × 4 | Same as raw size |
Native SegWit | (base × 4) + witness | ~25% smaller than raw size |
Example Calculation
Consider a SegWit transaction with:
- Base size: 200 bytes
- Witness size: 100 bytes
Minimum Relay Fee Rate
Nodes enforce a minimum fee rate to prevent spam:
- Default minimum: 1 sat/vbyte
- Transactions below this rate are typically rejected
- You can check your node's setting:
$ bitcoin-cli getmempoolinfo
{
"loaded": true,
"size": 47293,
"bytes": 32883821,
"usage": 148075552,
"maxmempool": 300000000,
"mempoolminfee": 0.00001000, # 1 sat/vbyte
...
}
NOTE
💡 The minimum relay fee is a policy rule, not a consensus rule. While theoretically possible, getting a below-minimum fee transaction mined is extremely unlikely unless you have a direct connection to a miner.
RPC: Current Fee Rates
You can estimate current fee rates using Bitcoin Core:
$ bitcoin-cli estimatesmartfee 6
{
"feerate": 0.00008124, # BTC/kB
"blocks": 6
}
Or query popular block explorers:
- mempool.space
- blockstream.info
- bitcoinfees.earn.com
Remember that fee rates are dynamic and can change rapidly based on network demand.