Bitcoin-MCP
Bitcoin-MCP is a comprehensive Bitcoin intelligence server providing AI agents with 49 tools to interact with the Bitcoin network, covering everything from fee analysis to transaction broadcasting.
Fee Intelligence: Get optimal fee recommendations across urgency tiers, estimate transaction costs in sats/USD before sending, compare fee sources side-by-side, and identify savings opportunities.
Blocks & Transactions: Analyze any block by height or hash (mining pool, SegWit/Taproot adoption, fee distribution), compare blocks, decode raw transactions (with inscription detection), and broadcast signed transactions to the network.
Mempool Analysis: Monitor congestion levels, fee buckets, transaction counts, look up specific unconfirmed transactions, and retrieve ancestor chains for CPFP analysis.
Mining Insights: Get current difficulty, hashrate, block reward, next block predictions, top 10 mining pool rankings, difficulty adjustment progress, and halving countdowns.
Network & Node Status: Monitor blockchain info, node health, peer connections, chain tips, transaction throughput, UTXO set size, and get a full situation summary (price, fees, mempool, mining in one call).
Address & UTXO Management: Validate and classify Bitcoin addresses, scan UTXOs, retrieve balances and paginated transaction history, check UTXO spent/unspent status, and get enriched transaction details with resolved input addresses.
Security Analysis: Analyze PSBTs for ordinals inscription listing mempool sniping vulnerabilities with plain-language risk explanations.
Market Data: Get current BTC/USD price, Fear & Greed Index, and Bitcoin supply/inflation info.
Utilities: Universal blockchain search, Bitcoin script decoding, Lightning Network BOLT11 invoice decoding, Bitcoin keypair generation, and Bitcoin Core RPC command help.
Flexible Setup: Works with zero configuration via a free hosted API (1,000 requests/day) or connects to a local Bitcoin Core node. Compatible with Claude Desktop, Claude Code, Cursor, VS Code, Zed, and Docker. Includes 6 built-in prompts for common workflows and 8 resources for context injection.
Provides a comprehensive suite of tools for querying the Bitcoin blockchain, analyzing mempool fee markets, decoding and broadcasting transactions, and monitoring mining economics via local or remote Bitcoin nodes.
Supports decoding BOLT11 Lightning invoices and enables Lightning-based payment interactions such as L402 micropayments through remote API integration.
bitcoin-mcp
Give any AI agent Bitcoin superpowers — fee intelligence, mempool analysis, and 50 tools backed by your Bitcoin node or compatible API.
50 standard tools · 6 prompts · 8 resources · Bitcoin Core or compatible API backend · MIT licensed
If bitcoin-mcp is useful to you, consider giving it a star — it helps others discover the project.
pip install bitcoin-mcpbitcoin-mcp needs a Bitcoin data backend. It auto-detects a local Bitcoin Core/Knots node from its cookie or RPC settings. Without a local node, set SATOSHI_API_URL to a compatible deployment.
Service status: the public Satoshi API previously hosted at
bitcoinsapi.comis paused and should not be treated as a working default. Use a local node or an explicitly configured compatible API.
Quick Start
Claude Desktop
Add to your claude_desktop_config.json:
{
"mcpServers": {
"bitcoin": {
"command": "uvx",
"args": ["bitcoin-mcp"]
}
}
}Claude Code
claude mcp add bitcoin -- uvx bitcoin-mcpCursor
Add to .cursor/mcp.json:
{
"mcpServers": {
"bitcoin": {
"command": "uvx",
"args": ["bitcoin-mcp"]
}
}
}VS Code
Add to .vscode/mcp.json:
{
"servers": {
"bitcoin": {
"command": "uvx",
"args": ["bitcoin-mcp"]
}
}
}Zed
Add to your Zed settings.json under context_servers:
{
"context_servers": {
"bitcoin": {
"command": "uvx",
"args": ["bitcoin-mcp"]
}
}
}See the Zed MCP docs for the current settings location and custom server flow.
Docker
docker build -t bitcoin-mcp .
docker run -i bitcoin-mcpOr with docker compose:
docker compose upPass environment variables to connect to a local Bitcoin Core node or a compatible API:
docker run -i -e BITCOIN_RPC_HOST=host.docker.internal -e BITCOIN_RPC_PORT=8332 bitcoin-mcp
# or
docker run -i -e SATOSHI_API_URL=https://your-api.example bitcoin-mcpAsk whether to send Bitcoin now
Use this as the first useful activation path after install:
"I need to send a Bitcoin transaction today. Use bitcoin-mcp to decide whether to send now or wait, and show the fee rate you used."
Expected path:
The agent calls
get_fee_recommendation.The answer gives a clear send now or wait recommendation with fee rates in sat/vB.
If the backend is unavailable, configure a local node or set
SATOSHI_API_URLbefore retrying.
After it works, Star this repo and share a short showcase with the prompt, tool call, and outcome so other Bitcoin agent builders can see the path.
Related MCP server: coin-mcp-server
Agent Integration
For repos that need Bitcoin tools, add bitcoin-mcp to the agent's MCP config and configure one of its supported backends:
Local Bitcoin Core/Knots RPC settings:
BITCOIN_RPC_HOST,BITCOIN_RPC_PORT, and optional credentials or datadirCompatible remote API:
SATOSHI_API_URLand, when required,SATOSHI_API_KEYSatoshi API source and integration reference: https://github.com/Bortlesboat/bitcoin-api/blob/main/docs/AGENT_INTEGRATION.md
Generated HTTP examples should use canonical Satoshi API /api/v1 paths.
Why bitcoin-mcp?
Fee intelligence that saves real money — know the cheapest time to send, compare fee tiers, estimate exact costs before broadcasting
Backend choice — use your own Bitcoin Core/Knots node or an explicitly configured compatible API
First Bitcoin MCP server on the Anthropic Registry
Top Use Cases
Ask your AI agent:
Prompt | What it does |
"What's the cheapest time to send Bitcoin today?" | Fee recommendation with savings breakdown |
"Analyze the current mempool congestion" | Real-time mempool depth, fee tiers, pending tx count |
"How much would I save waiting 6 blocks vs next block?" | Side-by-side fee comparison across confirmation targets |
"Search for this transaction: abc123..." | Full transaction decode with inscription detection |
"Give me a situation summary of Bitcoin right now" | Price, fees, mempool, mining, difficulty — one call |
Full Tool Reference
Fee Intelligence
Tool | Description |
| Optimal fee rate with urgency tiers and savings tips |
| Fee estimates across all confirmation targets |
| Fee estimate for a specific confirmation target |
| Side-by-side comparison of fee sources |
| Exact cost estimate for a transaction before sending |
Blocks & Transactions
Tool | Description |
| Deep analysis of any block by height or hash |
| Statistical breakdown of a block |
| Current chain height |
| Compare two blocks side by side |
| Search a range of blocks |
| Full transaction analysis with inscription detection |
| Decode a raw transaction hex |
| Broadcast a signed transaction |
| Check if a UTXO is spent or unspent |
Mempool
Tool | Description |
| Full mempool analysis — depth, fees, congestion |
| Mempool size, bytes, fee floor |
| Details for a specific unconfirmed transaction |
| Ancestor chain for a mempool transaction |
Mining
Tool | Description |
| Current mining difficulty, hashrate, block reward |
| Preview of the next block template |
| Top mining pools by recent blocks |
| Time and percentage of next difficulty change |
| Blocks and estimated time until next halving |
Network & Status
Tool | Description |
| Chain state, verification progress, softfork status |
| Node version, connections, relay info |
| Connection status and node health |
| Connected peer details |
| Active and stale chain tips |
| Transaction throughput over N blocks |
| UTXO set size and total supply |
| Circulating supply, inflation rate, percent mined |
| Aggregated overview — price, fees, mempool, mining |
| Current BTC/USD price |
| Fear/greed index and market indicators |
Address & UTXO
Tool | Description |
| UTXOs for an address |
| Validate and classify a Bitcoin address |
Indexed Address (requires blockchain indexer)
Tool | Description |
| Total received/sent/balance, tx count, first/last seen |
| Paginated transaction history with net value change |
| Transaction history with per-transaction value details |
| Enriched tx with resolved input addresses + spent status |
| Sync progress, ETA, blocks/sec |
Security
Tool | Description |
| Security analysis of a Partially Signed Bitcoin Transaction |
| Security guide for ordinal inscription listings |
Utility
Tool | Description |
| Universal search — address, txid, block hash, or height |
| Generate a new Bitcoin keypair |
| Decode and explain a Bitcoin script |
| Decode a Lightning Network BOLT11 invoice |
| Help text for any Bitcoin Core RPC command |
| List all available RPC commands |
| Decode and inspect an extended public key |
Optional Remote API Tool
query_remote_api is registered only when SATOSHI_API_URL is set and the l402 extra is installed. It queries canonical /api/v1 routes on that explicitly configured endpoint.
Configuration
Configure either a local Bitcoin Core/Knots node or a compatible remote API. If neither is available, bitcoin-mcp exits its connection check with a setup error instead of silently selecting an unavailable public service.
CLI Flags
bitcoin-mcp supports the following runtime flags:
Flag | Values | Default | Description |
|
|
| MCP transport to run |
| hostname / IP |
| Bind host for |
| integer |
| Bind port for |
|
|
| Server log verbosity |
Example:
bitcoin-mcp --transport sse --host 127.0.0.1 --port 8000 --log-level DEBUGVariable | Description | Default |
| Bitcoin Core RPC host |
|
| Bitcoin Core RPC port | Auto by network |
|
|
|
| Compatible Satoshi API base URL | None |
| API key for authenticated access | None |
To connect to a local Bitcoin Core node:
{
"mcpServers": {
"bitcoin": {
"command": "uvx",
"args": ["bitcoin-mcp"],
"env": {
"BITCOIN_RPC_HOST": "127.0.0.1",
"BITCOIN_RPC_PORT": "8332"
}
}
}
}Prompts & Resources
6 built-in prompts for common workflows:
analyze_fee_environment, investigate_transaction, monitor_mempool_fees, taproot_adoption_report, network_health_report, track_transaction
8 resources for context injection:
bitcoin://connection/status, bitcoin://node/status, bitcoin://fees/current, bitcoin://fees/history, bitcoin://mempool/snapshot, bitcoin://protocol/script-opcodes, bitcoin://protocol/address-types, bitcoin://protocol/sighash-types
Links
Satoshi API source — optional compatible backend implementation (public hosted service currently paused)
Anthropic MCP Registry —
io.github.Bortlesboat/bitcoin-mcp
Examples
See the examples/ folder for documented usage patterns:
Fee Analysis — find optimal send timing
Mempool Monitor — track congestion
Transaction Investigation — decode and analyze transactions
Block Analysis — inspect and compare blocks
Support This Project
bitcoin-mcp is free, open-source Bitcoin infrastructure. Support development through OpenSats.
Contributing
Contributions are welcome. See CONTRIBUTING.md for guidelines, including how to add new tools and the PR checklist.
Please report security vulnerabilities privately — see SECURITY.md.
About
bitcoin-mcp is created and maintained by Andrew Barnes, bridging AI agents and Bitcoin infrastructure through the Model Context Protocol.
Related projects:
Satoshi API — Bitcoin fee intelligence API, 108 endpoints, usable as a self-hosted compatible backend
ChainPulse — AI-powered Bitcoin network intelligence CLI
BAIP-1 — Bitcoin Agent Identity Protocol
bitcoin-fee-observatory — Fee market analytics dashboard
License
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseCqualityCmaintenanceA Model Context Protocol implementation for the CoinMarketCap API that provides standardized access to cryptocurrency market data, exchange information, and blockchain metrics.2612751MIT
- MIT
- Alicense-qualityBmaintenanceProvides real Bitcoin full node data via 17 tools, with pay-per-call in USDC on Base mainnet. Free tools include blockchain info, fees, and mempool; paid tools enable transaction tracking, address analysis, and more.MIT
- FlicenseBqualityDmaintenanceEnables Bitcoin blockchain data retrieval and analysis through free APIs, including transaction, address, market data, and network metrics.123
Related MCP Connectors
Provide AI agents and automation tools with contextual access to blockchain data including balance…
52 paid x402 API endpoints for AI agents — crypto, data, DeFi, market intelligence.
32 paid x402 endpoints for crypto, Zora & on-chain analysis. 10 MCP tools. USDC on Base.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Bortlesboat/bitcoin-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server