An MCP (Model Context Protocol) server that provides EUR exchange rates sourced directly from the European Central Bank (ECB). Connect it to Claude to look up historical rates and convert amounts between EUR and 30 other currencies by date.
| Tool | Description |
|---|---|
get_exchange_rate |
Returns the ECB rate for a given EUR/X currency pair and date |
convert_currency |
Converts an amount between EUR and another currency using the ECB rate for a given date |
If the requested date falls on a weekend or public holiday, the server automatically returns the most recent available rate (looking back up to 10 days). Every response includes a direct link to the ECB CSV data for the date used, so the source can be verified.
AUD, BGN, BRL, CAD, CHF, CNY, CZK, DKK, GBP, HKD, HUF, IDR, ILS, INR, ISK, JPY, KRW, MXN, MYR, NOK, NZD, PHP, PLN, RON, SEK, SGD, THB, TRY, USD, ZAR
Conversions must involve EUR on one side (e.g. EUR→GBP or JPY→EUR). Cross-rate conversions (e.g. GBP→JPY) and EUR→EUR are not supported.
- Rust (edition 2024, stable toolchain)
Pre-built binaries for Linux x86_64, macOS arm64, and Windows x86_64 are attached to each GitHub Release. Download the binary for your platform and place it somewhere on your PATH.
git clone https://github.com/lazy404/exchange_rates.git
cd exchange_rates
cargo build --releaseThe binary will be at target/release/exchange_rates.
-
Open (or create) the Claude Desktop configuration file:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
- macOS:
-
Add the server under
mcpServers:
{
"mcpServers": {
"exchange-rates": {
"command": "/absolute/path/to/exchange_rates/target/release/exchange_rates"
}
}
}- Restart Claude Desktop. The exchange rate tools will appear in the tools panel.
Register the server with the Claude Code CLI:
claude mcp add exchange-rates /absolute/path/to/exchange_rates/target/release/exchange_ratesOr add it to your project's .mcp.json so all project collaborators pick it up automatically:
{
"mcpServers": {
"exchange-rates": {
"command": "/absolute/path/to/exchange_rates/target/release/exchange_rates"
}
}
}Once connected, you can ask Claude naturally:
- "What was the EUR/USD rate on 15 January 2025?"
- "Convert 250 USD to EUR using the ECB rate for last Friday."
- "How much is €1,500 in Japanese yen as of 2024-12-31?"
- "What's the EUR/GBP rate for today?"
- Currencies: EUR ↔ X only. Exactly one side of every conversion must be EUR (EUR→EUR is rejected).
- Dates: rates are available only for ECB trading days. The server walks back up to 10 days to find the nearest published rate, so weekends and public holidays resolve automatically.
- Future dates: rejected with an explicit error.
- Data source: ECB Data Portal — rates are fetched live and cached in memory per (currency, calendar year) for the lifetime of the server process.
cargo check # fast compile check
cargo test # run tests — most require internet access (hits the live ECB API)
cargo clippy # lint
cargo fmt # format