home / mcp / mempool mcp server
Mempool.space MCP server implementation to get info from Bitcoin with support for getting it on your local Bitcoin node such as Umbrel, MyNode and others.
Configuration
View docs{
"mcpServers": {
"alexandresanlim-mempool-mcp-server": {
"command": "npx",
"args": [
"@sanlim/mempool-mcp-server"
],
"env": {
"MEMPOOL_BASE_URL": "http://umbrel.local:3006/api"
}
}
}
}You can access real-time Bitcoin blockchain and mempool data through a compact MCP server that exposes a suite of tools via the Model Context Protocol. Run it locally or invoke it via your MCP client to query current network statistics, fees, price data, blocks, transactions, and more in real-time.
Launch the server as an MCP tool provider and connect your MCP client to its standard input/output interface. You can use it directly with an MCP client such as Claude, Cursor, or your own client to query Bitcoin network data through the available tools. To run locally, start the server using the provided commands and then configure your client to point at the local process.
Practical usage patterns you can follow include: querying the current difficulty and price data, fetching mempool information, retrieving block and transaction details, and obtaining UTXO and address-related information. Use these tools to build real-time dashboards, trading tooling, or monitoring that reacts to network conditions.
Prerequisites you need before installing are: a recent Node.js runtime and npm. The following steps show two common ways to run the MCP server: via npx for quick start and a local build for development.
# Quick start: use the MCP server via npx
"mempool-mcp-server": {
"command": "npx",
"args": [
"@sanlim/mempool-mcp-server"
]
}Optionally run a local build for development and full control over the runtime. The steps below assume you clone the project, install dependencies, build the project, and run the server from the built output.
git clone https://github.com/alexandresanlim/mempool-mcp-server.git
cd mempool-mcp-server
npm install
npm run build
npm run serverIf you want to connect to a private or local mempool API, you can replace the default API endpoint by setting an environment variable when you run the server. For example, you can point to a local mempool API provided by a Bitcoin node or hosting environment.
Example local configuration for using a local mempool API in a client setup:
"mempool-mcp-server-local": {
"command": "npx",
"args": [
"@sanlim/mempool-mcp-server"
],
"env": {
"MEMPOOL_BASE_URL": "http://umbrel.local:3006/api"
}
}Get current and next Bitcoin difficulty adjustment info.
Get the current BTC price in various fiat currencies.
Get the BTC price for a specific date (YYYY-MM-DD).
Get recommended Bitcoin transaction fees.
Get general Bitcoin network statistics.
Get mining pools info.
Get info for a specific mining pool.
Get mining blocks fees for the last 24h.
Get mempool info.
Get mempool txids.
Get recent mempool transactions.
Get the latest blocks.
Get details about a block from its hash.
Get txids for a block.
Get transactions for a block.
Get block status.
Get raw block hex.
Get block txid by index.
Get the block header in hex.
Get details about an address.
Get transactions for an address.
Get chain transactions for an address.
Get mempool transactions for an address.
Get UTXOs for an address.
Get details about a transaction.
Get transaction status.
Get raw transaction hex.
Get transaction merkleblock proof.
Get outspend info for a transaction output.
Get outspends for all outputs of a transaction.