EVM

An MCP server that provides complete access to Ethereum Virtual Machine (EVM) JSON-RPC methods. Works with any EVM-compatible node provider including Infura, Alchemy, QuickNode, local nodes, and more.
  • typescript

0

GitHub Stars

typescript

Language

7 months ago

First Indexed

3 months ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs

This MCP server provides full EVM JSON-RPC access through a configurable MCP endpoint. You can connect to Ethereum-compatible networks via Infura, Alchemy, QuickNode, or your own node, and then query data, send transactions, estimate gas, listen for events, and interact with smart contracts from your AI workflows.

How to use

You will run a local or remote MCP server that exposes EVM JSON-RPC methods to your tooling. Connect your MCP client to either an HTTP endpoint or a local stdio server, then perform RPC calls through the server as if you were talking directly to an EVM node. Use the provided environment variables to point the server at your chosen RPC endpoint and chain.

How to install

Prerequisites: Node.js 18+ and npm or a compatible JavaScript runtime.

# Clone the project
git clone https://github.com/JamesANZ/evm-mcp.git
cd evm-mcp

# Install dependencies
npm install

# Build the project
npm run build

# Set runtime configuration (example values shown; replace with real keys)
export RPC_URL="https://mainnet.infura.io/v3/YOUR_API_KEY"
export CHAIN_ID="1"

# Start the MCP server
npm start

Configuration

Configure how the MCP server connects to the EVM network by setting environment variables. You can use a public RPC endpoint or your own node. The following examples illustrate common setups.

# Example using Infura
RPC_URL=https://mainnet.infura.io/v3/YOUR_API_KEY
CHAIN_ID=1

# Example using Alchemy
RPC_URL=https://eth-mainnet.g.alchemy.com/v2/YOUR_API_KEY
CHAIN_ID=1

# Example using a local node
RPC_URL=http://localhost:8545
CHAIN_ID=1

Security and best practices

Keep your RPC URL private and rotate API keys regularly. If you expose the server over a network, restrict access to trusted clients and consider IP whitelisting or VPN access. Use separate RPC endpoints for development and production, and monitor usage for unusual patterns.

Troubleshooting

If the server fails to start, verify that Node.js is installed and the dependencies are built. Check that RPC_URL is reachable and that CHAIN_ID matches your target network. Review logs for connection errors or authentication issues with your RPC provider.

Examples of common RPC methods (tool references)

Below are representative RPC methods you can invoke through the MCP server to interact with Ethereum-compatible networks.

Practical usage with the client

When using your MCP client, send calls using the exposed tools that map to standard EVM JSON-RPC methods. For example, fetch balance, query block data, or submit a transaction through the MCP endpoint that you started with npm start.

Available tools

eth_blockNumber

Get the latest block number from the connected EVM network.

eth_getBalance

Retrieve the balance of a specific address at a given block or latest state.

eth_getTransactionCount

Return the number of transactions sent from an address (nonce).

eth_getBlockByNumber

Fetch block details by block number or tag like latest.

eth_getTransactionByHash

Obtain details of a transaction by its hash.

eth_getTransactionReceipt

Get the receipt for a transaction, including status and gas usage.

eth_getCode

Return the bytecode at a given contract address.

eth_getStorageAt

Read storage at a contract’s slot.

eth_call

Simulate a contract call and return the result without making a transaction.

eth_estimateGas

Estimate gas required for a transaction.

eth_sendRawTransaction

Submit a signed transaction to the network.

eth_gasPrice

Query the current gas price on the network.

eth_getLogs

Query event logs that match given filters.

eth_chainId

Retrieve the chain ID of the connected network.

net_version

Return the network protocol version.

net_listening

Check if the node is listening for network connections.

net_peerCount

Return the number of peers connected to the node.

web3_clientVersion

Query the client version of the connected node.

web3_sha3

Hash data with Keccak-256.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational