Rubic MCP Server: Cross-Chain Token Swaps for AI Agents

Install Rubic MCP Server to let Claude, Cursor, VS Code, and other MCP-compatible AI agents quote, simulate, build, sign, broadcast, and track token swaps across 70+ chains. Open-source, non-custodial, and built for simulation-first DeFi workflows.

What Is Rubic MCP Server?

Rubic MCP Server is a Model Context Protocol server that gives AI agents structured access to cross-chain and on-chain DeFi workflows.

Instead of relying on browser automation, fragile scripts, or unstructured prompts, Rubic MCP Server exposes typed MCP tools that let AI agents quote routes, simulate swaps, build transactions, track execution, and interact with token swaps across 70+ chains.

The server is designed for developers building AI-powered DeFi workflows inside Claude, Cursor, VS Code, Windsurf, Cline, Continue, Zed, and other MCP-compatible environments.

Rubic MCP Server is open-source, non-custodial, and built around simulation-first execution.

Why MCP Matters for DeFi

Model Context Protocol (MCP) is becoming the standard way for AI assistants and coding agents to interact with external tools.

Instead of parsing web pages or clicking through interfaces, AI agents can call structured tools with predictable inputs and outputs.

For DeFi applications, this matters because token swaps involve: route discovery, fee estimation, gas calculations, slippage handling, transaction simulation, risk analysis, signing workflows, and broadcast and status tracking.

Generic browser automation is unreliable for these workflows. AI agents need deterministic tools.

Rubic MCP Server provides those tools.

What Rubic MCP Server Enables

With Rubic MCP Server, AI agents can quote cross-chain token swaps, compare multiple swap routes, simulate execution before approval, build swap transactions, generate calldata, track transaction status, open browser-based fallback flows, and work across EVM and non-EVM ecosystems.

This makes Rubic MCP Server useful for AI-powered DeFi assistants, autonomous trading workflows, portfolio management agents, cross-chain automation, developer tooling, internal crypto operations tools, AI-enhanced wallets, and DeFi copilots.

Cross-Chain Token Swaps Through AI Agents

Rubic MCP Server supports cross-chain and on-chain token swaps through Rubic’s routing infrastructure.

Developers can integrate AI-driven swap workflows directly into MCP-compatible clients like Claude Desktop, Cursor, and VS Code.

Instead of manually opening a bridge or DEX aggregator, users can describe the desired outcome in natural language.

Examples:

  • “Swap 500 USDC from Ethereum to Arbitrum.”
  • “Find the cheapest route from Base to Polygon.”
  • “Simulate this swap before signing.”
  • “Open this route in Rubic.”

The AI agent selects the appropriate MCP tools automatically.

Structured DeFi Tools for AI Agents

One of the biggest advantages of Rubic MCP Server is structured execution.

Many AI-driven crypto workflows rely on browser actions, prompt engineering, or brittle automation layers.

Rubic MCP Server instead provides typed MCP tools with predictable schemas and typed error handling.

This means AI agents can plan execution flows reliably, recover from errors programmatically, compare routes consistently, simulate swaps before approval, surface risks to users, and re-plan when conditions change.

The architecture is designed for agentic workflows rather than one-off automation demos.

Simulation-First DeFi Workflows

Most DeFi tools move directly from prompt to transaction. Rubic MCP Server is built around simulation-first execution.

Before a swap is signed, AI agents can preview expected output, estimated fees, gas costs, price impact, route details, estimated duration, and risk indicators.

This gives users visibility into the trade before execution.

Simulation-first workflows are especially important for cross-chain transfers, high-value swaps, AI-driven automation, enterprise DeFi tooling, and agent safety systems.

Supported Chains and Ecosystems

Rubic MCP Server supports swap workflows across 70+ blockchain networks.

This includes both EVM and non-EVM ecosystems.

EVM Networks

Ethereum, Arbitrum, Polygon, BNB Chain, Optimism, Base, zkSync Era, Monad, Scroll, MegaETH, Plasma, HyperEVM, Avalanche, Berachain, Unichain, Soneium, Fraxtal, Linea, Mode, Blast, Mantle, Metis, Manta Pacific, zkEVM, PulseChain, Taiko, Hemi, XLayer, Flare

EVM chains support:

  • Local signing
  • Full execution
  • Broadcast workflows
  • Transaction tracking
  • Simulation
  • Route comparison

Non-EVM Networks

Tron, Bitcoin, Solana, ZCash, TON, Sui, Filecoin, Dash, Monero, Cardano, Cosmos, Litecoin, XRP Ledger, Aptos, Polkadot, Stellar, Near, Zilliqa, Tezos, XDC, Kava, Neo

Non-EVM ecosystems use browser-based confirmation through rubic_get_swap_url.

This enables AI agents to:

  • Discover routes
  • Simulate swaps
  • Generate fallback links
  • Continue execution through Rubic Exchange

MCP-Compatible AI Tools and IDEs

Rubic MCP Server works with popular MCP-compatible developer tools and AI environments.

Supported clients include Claude Desktop, Claude Code, Cursor, VS Code, Windsurf, Cline, Continue, and Zed.

Because Rubic MCP Server follows MCP standards, developers can integrate it into custom AI environments and internal workflows as well.

Rubic MCP Tools Included

Rubic MCP Server exposes multiple tools for read-only and execution workflows.

Without a configured private key, developers can still access discovery and simulation functionality.

With a locally configured key, full execution workflows become available.

Core tools include:

  • rubic_get_routes
  • rubic_simulate_swap
  • rubic_build_swap_tx
  • rubic_track_tx_status
  • rubic_get_swap_url

The tool architecture is intentionally modular.

Quote, simulation, transaction building, signing, and tracking are separated into independent steps so AI agents can pause, retry, branch logic, or request approval when needed.

Non-Custodial Security Model

Rubic MCP Server is non-custodial by design. Private keys never leave the local environment.

Local Signing

Private keys are read locally from EVM_WALLET_PRIVATE_KEY.

Signing happens locally in-process via viem.

There is no external signer, remote relay, key custody, or server-side key handling.

Read-Only Mode

Without a private key configured, Rubic MCP Server operates in read-only mode.

This still allows route discovery, quotes, simulation, calldata generation, status tracking, and guidance workflows.

Rubic API and Keys

The Rubic API receives swap parameters and returns calldata.

It never receives private keys.

Why Developers Use Rubic MCP Server

Developers building AI agents need infrastructure that is:

  • Predictable
  • Structured
  • Secure
  • Cross-chain
  • Compatible with modern AI tooling

Rubic MCP Server solves several problems at once:

Reliable Agent Workflows

Typed schemas and semantic error codes allow agents to recover gracefully instead of parsing raw strings.

Cross-Chain Infrastructure

Developers do not need to manually integrate multiple bridges, DEXs, or routing systems.

Faster AI Integration

Rubic MCP Server plugs directly into MCP-compatible environments.

Better User Safety

Simulation-first flows reduce execution ambiguity and improve user visibility before signing.

AI Agent DeFi Use Cases

Rubic MCP Server can power a wide range of AI-native crypto applications.

AI Trading Assistants

Agents can compare routes, evaluate costs, and execute swaps after approval.

Portfolio Rebalancing

AI workflows can rebalance assets across multiple chains.

Cross-Chain Treasury Operations

Internal tools can automate treasury routing and bridge execution.

Crypto Copilots

Users can interact with DeFi through conversational prompts instead of manual interfaces.

Research and Simulation

Agents can analyze swap outcomes before users commit capital.

Browser-Based Fallback Workflows

Not all ecosystems support local execution.

For non-EVM flows or manual approval workflows, Rubic MCP Server can generate a Rubic Exchange URL using rubic_get_swap_url.

This creates a browser-based fallback path while preserving the agent workflow.

Fallback support is useful for:

  • Non-EVM ecosystems
  • Manual signing
  • Human review flows
  • Compliance workflows
  • Hybrid AI + user execution models

Technical Details and Limitations

Rubic MCP Server is designed to make execution behavior explicit.

Quotes Are Estimates

Actual execution prices may differ due to:

  • Slippage
  • MEV
  • Gas fluctuations
  • Market movements

Simulation Improves Visibility

Simulation reduces uncertainty but does not eliminate market risk.

Chain Support Differences

EVM chains support full local execution.

Non-EVM ecosystems rely on browser fallback flows.

Typed Error Handling

Errors are returned as semantic codes that AI agents can branch on programmatically.

How to Install Rubic MCP Server

Rubic MCP Server uses:

npx -y @cryptorubic/mcp

Developers can add a JSON configuration block to Claude, Cursor, VS Code, Windsurf, Cline, Continue, Zed, or any MCP-compatible client.

Once configured, AI agents can begin interacting with Rubic’s swap infrastructure immediately.

Why Rubic MCP Server Matters

AI agents are becoming a new interface layer for crypto. But DeFi workflows require more than chat interfaces.

They require structured execution, deterministic tooling, cross-chain routing, simulation-first flows, non-custodial signing, and reliable recovery logic.

Rubic MCP Server provides this infrastructure through MCP.

It enables AI agents to interact with DeFi workflows in a predictable, secure, and developer-friendly way.

Start Building with Rubic MCP Server

Rubic MCP Server is built for developers who want AI agents to handle real DeFi workflows instead of generic browser automation.

From route discovery to transaction tracking, the server provides structured tools for cross-chain and on-chain swaps across 70+ ecosystems.

Developers can integrate Rubic MCP Server into AI assistants, IDEs, internal tooling, automation pipelines, and next-generation DeFi applications.

Install Rubic MCP Server and start building AI-powered DeFi workflows today.

Rubic MCP Server FAQ

What is Rubic MCP Server? An open-source MCP server that gives AI agents like Claude, Cursor, and VS Code structured tools to quote, simulate, build, sign, broadcast, and track token swaps across 70+ blockchain networks.

What is Model Context Protocol (MCP)? An open standard that lets AI agents call external tools in a structured, deterministic way. MCP servers expose typed tools that clients can discover and invoke.

Which AI clients work with Rubic MCP Server? Claude Desktop, Cursor, VS Code (with the MCP extension), and any other MCP-compatible client.

Is Rubic MCP Server non-custodial? Yes. Your private key is stored locally in your environment. Rubic never receives, stores, or proxies your keys. Signing happens locally.

How many chains does Rubic MCP Server support? 70+ chains for both cross-chain and on-chain swaps.

How many MCP tools are included? 13 tools in v0.2.0, covering the full swap lifecycle from route discovery through broadcast and tracking.

Is Rubic MCP Server free? Yes. It’s open-source and free to use. Standard on-chain swap fees apply, as with any DEX or bridge.

Website |  + posts

Content Lead at Rubic with a deep dive into Web3 trends, industry narratives, and market analysis