loading…
Search for a command to run...
loading…
An MCP server that provides complete access to Ethereum Virtual Machine (EVM) JSON-RPC methods. Works with any EVM-compatible node provider including Infura, Al
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.
Complete EVM JSON-RPC access in your AI workflow. Query any EVM-compatible network (Ethereum, Polygon, Arbitrum, Optimism, BSC, and more) through any node provider. Works with Infura, Alchemy, QuickNode, local nodes, and more.
An MCP (Model Context Protocol) server that provides comprehensive access to Ethereum Virtual Machine (EVM) JSON-RPC methods for AI coding environments like Cursor and Claude Desktop.
Ready to interact with EVM blockchains? Install in seconds:
Install in Cursor (Recommended):
Or install manually:
npm install -g @jamesanz/evm-mcp
# Or from source:
git clone https://github.com/JamesANZ/evm-mcp.git
cd evm-mcp && npm install && npm run build
eth_blockNumber – Get latest block numbereth_getBalance – Get account balanceeth_getTransactionCount – Get transaction count (nonce)eth_getBlockByNumber – Get block informationeth_getTransactionByHash – Get transaction detailseth_getTransactionReceipt – Get transaction receipteth_getCode – Get contract bytecodeeth_getStorageAt – Get storage valueeth_call – Execute contract calleth_estimateGas – Estimate gas for transactioneth_sendRawTransaction – Send signed transactioneth_gasPrice – Get current gas priceeth_getLogs – Get event logslist_supported_networks – List configured networks and providerseth_chainId – Get chain IDnet_version – Get network versionnet_listening – Check if listeningnet_peerCount – Get peer countweb3_clientVersion – Get client versionweb3_sha3 – Hash data with Keccak-256Click the install link above or use:
cursor://anysphere.cursor-deeplink/mcp/install?name=evm-mcp&config=eyJldm0tbWNwIjp7ImNvbW1hbmQiOiJucHgiLCJhcmdzIjpbIi15IiwiQGphbWVzYW56L2V2bS1tY3AiXX19
Requirements: Node.js 18+ and npm
# Clone and build
git clone https://github.com/JamesANZ/evm-mcp.git
cd evm-mcp
npm install
npm run build
# Set provider API keys
export INFURA_API_KEY="your-infura-api-key"
export DEFAULT_NETWORK="ethereum"
export DEFAULT_PROVIDER="infura"
# Run server
npm start
Add to claude_desktop_config.json:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"evm-mcp": {
"command": "node",
"args": ["/absolute/path/to/evm-mcp/build/index.js"],
"env": {
"INFURA_API_KEY": "your-infura-api-key",
"DEFAULT_NETWORK": "ethereum",
"DEFAULT_PROVIDER": "infura",
"RPC_PROVIDER_ORDER": "infura,alchemy"
}
}
}
}
Restart Claude Desktop after configuration.
| Variable | Required | Description |
|---|---|---|
INFURA_API_KEY |
One of* | Infura project API key (built-in preset) |
ALCHEMY_API_KEY |
One of* | Alchemy app API key (built-in preset) |
DEFAULT_NETWORK |
No | Default chain slug or chain ID (default: ethereum) |
DEFAULT_PROVIDER |
No | Provider slug to prefer (infura, alchemy, or custom) |
RPC_PROVIDER_ORDER |
No | Comma-separated provider fallback order (default: infura,alchemy) |
CUSTOM_PROVIDERS |
One of* | JSON array of user-defined providers |
CUSTOM_NETWORKS |
One of* | JSON array of user-defined networks |
*At least one provider API key, custom provider, or custom network with rpcUrl is required.
Set an API key and the server builds RPC URLs automatically for supported networks:
{
"INFURA_API_KEY": "your-infura-key",
"DEFAULT_NETWORK": "ethereum",
"DEFAULT_PROVIDER": "infura",
"RPC_PROVIDER_ORDER": "infura,alchemy"
}
Each RPC tool accepts an optional network parameter (slug, name, or chain ID). When omitted, DEFAULT_NETWORK is used.
{
"tool": "eth_chainId",
"arguments": { "network": "polygon" }
}
Use list_supported_networks to discover configured networks and providers.
CUSTOM_PROVIDERS)Register any RPC provider by supplying a base URL template and network-specific URLs:
"CUSTOM_PROVIDERS": "[{\"slug\":\"quicknode\",\"apiKeyEnv\":\"QUICKNODE_API_KEY\",\"baseUrl\":\"https://rpc.example.com/v1/{apiKey}\",\"networkUrls\":{\"ethereum\":\"https://eth.quiknode.pro/{apiKey}/\",\"polygon\":\"https://polygon.quiknode.pro/{apiKey}/\"}}]"
networkUrls values are used directly (with {apiKey} substitution)./) are appended to baseUrl.CUSTOM_NETWORKS)Register arbitrary chains by name:
"CUSTOM_NETWORKS": "[{\"name\":\"HyperEVM\",\"slug\":\"hyperevm\",\"chainId\":999,\"rpcUrl\":\"https://rpc.hyperliquid.xyz/evm\"}]"
Or route through a provider by setting provider and adding the network slug to that provider's networkUrls.
- "RPC_URL": "https://mainnet.infura.io/v3/KEY"
- "CHAIN_ID": "1"
+ "INFURA_API_KEY": "KEY"
+ "DEFAULT_NETWORK": "ethereum"
+ "DEFAULT_PROVIDER": "infura"
Configuration changes require restarting the MCP server.
CUSTOM_NETWORKSQuery the current block number:
{
"tool": "eth_blockNumber",
"arguments": {}
}
Check an address balance:
{
"tool": "eth_getBalance",
"arguments": {
"address": "0x742d35Cc6634C0532925a3b8D6Ac6e2F0C4C9B7C",
"blockNumber": "latest"
}
}
View transaction information:
{
"tool": "eth_getTransactionByHash",
"arguments": {
"txHash": "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"
}
}
Execute a contract call:
{
"tool": "eth_call",
"arguments": {
"to": "0xA0b86a33E6441c8C06DDD46C310c0eF8D9441C8F",
"data": "0x70a08231000000000000000000000000742d35Cc6634C0532925a3b8D6Ac6e2F0C4C9B7C"
}
}
Query contract events:
{
"tool": "eth_getLogs",
"arguments": {
"fromBlock": "0x1234567",
"toBlock": "latest",
"address": "0xA0b86a33E6441c8C06DDD46C310c0eF8D9441C8F",
"topics": [
"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef"
]
}
}
Built with: Node.js, TypeScript, MCP SDK, Ethers.js
Dependencies: @modelcontextprotocol/sdk, ethers, zod
Platforms: macOS, Windows, Linux
Environment Variables: See Configuration above.
⭐ If this project helps you, please star it on GitHub! ⭐
Contributions welcome! Please open an issue or submit a pull request.
MIT License – see LICENSE.md for details.
If you find this project useful, consider supporting it:
⚡ Lightning Network
lnbc1pjhhsqepp5mjgwnvg0z53shm22hfe9us289lnaqkwv8rn2s0rtekg5vvj56xnqdqqcqzzsxqyz5vqsp5gu6vh9hyp94c7t3tkpqrp2r059t4vrw7ps78a4n0a2u52678c7yq9qyyssq7zcferywka50wcy75skjfrdrk930cuyx24rg55cwfuzxs49rc9c53mpz6zug5y2544pt8y9jflnq0ltlha26ed846jh0y7n4gm8jd3qqaautqa
₿ Bitcoin: bc1ptzvr93pn959xq4et6sqzpfnkk2args22ewv5u2th4ps7hshfaqrshe0xtp
Ξ Ethereum/EVM: 0x42ea529282DDE0AA87B42d9E83316eb23FE62c3f
Run in your terminal:
claude mcp add jamesanz-evm-mcp -- npx pro tip
Just installed JamesANZ/evm-mcp? Say to Claude: "remember why I installed JamesANZ/evm-mcpand what I want to try" — it'll save into your Vault.
how this works →Security
Low riskAutomated heuristic from public metadata — not a security guarantee.