Exchange Rate API

Real-time & historical exchange rates for 160+ currencies, mid-market (Reuters/Refinitiv).

OtherJavaScriptv1.0.2

@exchangerateapi/mcp-server

Powered by Exchange-RateAPI

npm license

MCP server that gives AI coding tools (Claude Code, Cursor, Claude Desktop, Windsurf) access to real-time and historical currency exchange rates from Exchange Rate API.

160+ currencies. Mid-market rates updated every 60 seconds. Sourced from institutional interbank market data.

Quick Setup

1. Get a Free API Key

Sign up at exchange-rateapi.com/register — free tier, no credit card.

2. Add to Your MCP Client

Claude Code (~/.claude/settings.json):

{
  "mcpServers": {
    "exchange-rateapi": {
      "command": "npx",
      "args": ["-y", "@exchangerateapi/mcp-server"],
      "env": { "EXCHANGE_RATE_API_KEY": "era_live_..." }
    }
  }
}

Cursor (.cursor/mcp.json):

{
  "mcpServers": {
    "exchange-rateapi": {
      "command": "npx",
      "args": ["-y", "@exchangerateapi/mcp-server"],
      "env": { "EXCHANGE_RATE_API_KEY": "era_live_..." }
    }
  }
}

Claude Desktop (claude_desktop_config.json):

{
  "mcpServers": {
    "exchange-rateapi": {
      "command": "npx",
      "args": ["-y", "@exchangerateapi/mcp-server"],
      "env": { "EXCHANGE_RATE_API_KEY": "era_live_..." }
    }
  }
}

Windsurf (~/.windsurf/mcp.json):

{
  "mcpServers": {
    "exchange-rateapi": {
      "command": "npx",
      "args": ["-y", "@exchangerateapi/mcp-server"],
      "env": { "EXCHANGE_RATE_API_KEY": "era_live_..." }
    }
  }
}

Tools

ToolDescription
get_exchange_rateGet the current mid-market rate between two currencies
get_historical_ratesGet historical data for a pair over 1d, 7d, 30d, or 1y
get_ratesMulti-target rates with date ranges and grouping (day/week/month)
list_currenciesList all 160+ supported currencies

Example Prompts

Once configured, ask your AI assistant:

  • "What's the current USD to EUR exchange rate?"
  • "Show me GBP/JPY rates for the last 30 days"
  • "Convert 5000 USD to EUR, GBP, and JPY"
  • "List all supported currencies"
  • "What's the monthly average EUR/USD rate for 2026?"

Environment Variables

VariableRequiredDescription
EXCHANGE_RATE_API_KEYYesYour API key from exchange-rateapi.com
EXCHANGE_RATE_BASE_URLNoOverride API base URL (default: https://exchange-rateapi.com/api)

Links

License

MIT

Installation

Source-derived launch command. Check the maintainer’s required arguments and credentials before running:

bash
npx -y @exchangerateapi/mcp-server

Set up in your AI client

Merge this template into ~/Library/Application Support/Claude/claude_desktop_config.json. Keep existing servers. Add any arguments, credentials, and permissions required by the maintainer; this template has not been install-tested.

json
{
  "mcpServers": {
    "io-github-exchange-rateapi-mcp-server": {
      "command": "npx",
      "args": [
        "-y",
        "@exchangerateapi/mcp-server"
      ]
    }
  }
}

Restart Claude Desktop completely for changes to take effect. Confirm the server appears connected in the client’s tool list, then try a read-only example from its documentation.

Claude Desktop setup reference

Package

@exchangerateapi/mcp-servernpm

Compatible MCP Clients

Exchange Rate API works with any MCP-compatible client. Copy the config snippet from the Configuration section above and add it to the file shown for your client, then restart the application.

  • Claude Desktop~/Library/Application Support/Claude/claude_desktop_config.jsonRestart Claude Desktop completely for changes to take effect.
  • Cursor~/.cursor/mcp.jsonRestart Cursor for changes to take effect.
  • VS Code.vscode/mcp.jsonReload VS Code window for changes to take effect.
  • Windsurf~/.codeium/windsurf/mcp_config.jsonRestart Windsurf for changes to take effect.
  • Claude Code.mcp.jsonSave at the project root, then start Claude Code in that project and review the MCP server approval prompt. Keep real credentials out of shared files.

Learn More