bitcoin-fees-advisor
bitcoin-fees-advisor is a REST + SSE API for Bitcoin fee estimation, updated every 10-30 seconds. It aggregates data from multiple sources and provides a complete fee management toolkit for production wallets, exchanges, and payment processors.
Use it when you need to:
- Display accurate sat/vB fee tiers to users before transaction signing
- Calculate RBF bump amounts for stuck transactions (BIP125)
- Plan CPFP child transactions to accelerate a stuck parent
- Target a specific confirmation window (confirm within N seconds at probability P)
- Optimize a batch of transactions for minimum total cost
- Monitor mempool conditions in real time via SSE
Endpoints
Fee recommendations
GET /fees - Current fee tiers
Returns fast / medium / slow sat/vB values.
# Basic fee tiers
curl https://api.overblock.io/bitcoin-fees/fees \
-H "X-API-Key: your-token"
# With txType: adds estimatedVsize and estimatedFeeSat
curl "https://api.overblock.io/bitcoin-fees/fees?txType=p2wpkh" \
-H "X-API-Key: your-token"
Supported txType values: p2pkh, p2sh-p2wpkh, p2wpkh, p2tr, p2wsh-2of3.
GET /fee-advisor/market - Full mempool state
Returns mempool tx count, total vbytes, fee histogram, thresholds for 1/3/6 blocks, miner bias, and avg block interval.
Advanced fee tools
POST /fee-advisor/rbf-bump - RBF replacement fee calculator
Given a stuck transaction, returns the minimum fee rate required to replace it per BIP125.
curl -X POST https://api.overblock.io/bitcoin-fees/fee-advisor/rbf-bump \
-H "X-API-Key: your-token" \
-H "Content-Type: application/json" \
-d '{
"currentFeeRateSatVb": 20,
"currentFeeSat": 2820,
"vsize": 141,
"targetBlocks": 1
}'
POST /fee-advisor/deadline - Deadline-based fee
Returns the fee rate needed to confirm a transaction within deadlineSec seconds at targetProbability.
POST /fee-advisor/cpfp - CPFP child fee planner
Given a stuck parent transaction, calculates the required fee for a child transaction to accelerate confirmation via CPFP.
POST /fee-advisor/batch - Batch transaction planner
Optimally distributes N transactions across time to minimize total fee cost, given a deadline.
Strategies: minimize_cost (wave scheduling), uniform (even distribution), asap (all immediately).
Transaction monitoring
GET /tx-status?txids=abc,def - Transaction status
Returns status for each txid: in_mempool, confirmed, replaced_by_rbf, or unknown.
Note: only tracks transactions observed since the crawler started. Historical lookups are not supported.
GET /address-seen?addresses=addr1 - Address activity
Returns whether an address has been seen in the mempool or confirmed blocks since startup.
Real-time streaming (SSE)
GET /fees/stream - Fee update stream
Server-Sent Events stream. Emits fees events (fast/medium/slow) and mempool events (tx count, vbytes). Throttled to at most one update per 30 seconds. Heartbeat every 25 seconds.
GET /events/stream?txids=abc&addresses=addr1 - Transaction watch stream
Emits events for specific txids and addresses: tx.seen, tx.confirmed, tx.replaced, address.activity.
Update interval
Fee recommendations are refreshed every 10-30 seconds based on mempool activity. During high congestion, updates are more frequent.
Billing
- Free - rate-limited requests per minute
- PAYG / requests - per API call, micro-USD per request
- Subscription / credits - monthly request credits pool
Next steps
Related reading: Bitcoin Fee Estimation for Developers · Integrating Fee Estimation into a Wallet