Get the FREE Ultimate OpenClaw Setup Guide →

infura

Infura MCP server! This project provides a ready-to-use Model Context Protocol (MCP) server that exposes the Infura JSON-RPC API as a set of tools for Large Language Models like Claude and Cursor.

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio qbandev-infura-mcp-server npx -y infura-mcp-server \
  --env INFURA_API_KEY="<YOUR_API_KEY>" \
  --env INFURA_NETWORK="mainnet"

How to use

The Infura MCP Server provides a bridge between AI assistants and Infura-backed blockchain data. It exposes 29 read-only JSON-RPC tools that let you query accounts, blocks, transactions, smart contracts, logs, and network information across 30+ networks (including Ethereum mainnet, testnets, and various Layer 2s) without requiring a local Web3 setup. You can configure the MCP server in your client (Claude, Cursor, VS Code Copilot, or HTTP deployments) to point to the Infura MCP endpoint and supply your Infura API key. Once configured, your AI client can issue standard MCP tool calls to fetch real-time blockchain data and receive structured results suitable for prompting and reasoning. Optional response_format: "markdown" can be used to obtain human-friendly outputs when desired.

How to install

Prerequisites:

  • Node.js and npm available on your system (for npx usage)
  • An Infura API key (from MetaMask Developer Portal)
  1. Install and run the MCP server via npx (no local install required):

    • Ensure you have an Infura API key ready.
    • Start the MCP server by configuring your client with: { "mcpServers": { "infura": { "command": "npx", "args": ["-y", "infura-mcp-server"], "env": { "INFURA_API_KEY": "<YOUR_API_KEY>", "INFURA_NETWORK": "mainnet" } } } }
  2. Alternatively, run via Docker (if preferred):

    • docker run --rm -i
      -e INFURA_API_KEY=<YOUR_API_KEY>
      -e INFURA_NETWORK=mainnet
      ghcr.io/qbandev/infura-mcp-server:latest
  3. For HTTP deployment (optional):

    • Use npm run start:http in your client project and connect to http://localhost:3001/mcp
    • Or configure your MCP client to point to the provided HTTP endpoint
  4. Validate installation:

    • In Claude: claude mcp list
    • In Cursor: check MCP configuration in Settings → MCP → Add new MCP server
    • In VS Code: ensure the mcp.json or equivalent settings include the infura server

Additional notes

Tips and caveats:

  • Ensure INFURA_API_KEY is kept secure; prefer env variable references in your client config.
  • INFURA_NETWORK defaults to mainnet but can be set to polygon-mainnet, etc., to target other networks supported by Infura.
  • All tools are read-only; they do not modify blockchain state.
  • If using HTTP mode, adjust PORT as needed and ensure CORS/host settings align with your client.
  • When diagnosing issues, enable DEBUG for verbose logs and verify that INFURA_API_KEY is valid and has the required network access.

Related MCP Servers

Sponsor this space

Reach thousands of developers