# XE API: Get historical exchange rate

> Gets XE's daily mid-market exchange rate for a past UTC date and converts an amount with it.

Unofficial. Not affiliated with or endorsed by XE.

- Page: https://fous.com/methods/xe.com/get-historical-rate
- Method: `xe.com/get_historical_rate`, version 1
- Website: xe.com
- Returns: date, currency codes and names, rate, inverse rate, converted amount, table link
- Effect: read (it gets data and changes nothing)
- Sign-in: none needed
- Cost: 1 credit per completed run (1¢ with pay as you go); failed runs are free
- Verified: Nov 2, 2026

## Inputs

| Field | Type | Required | In the run below | Description |
|---|---|---|---|---|
| `date` | string | yes | `"2023-06-12"` | Past date of the XE daily UTC table, for example 2024-01-15. |
| `amount` | number | no | `25` | Amount of the starting currency to convert, for example 100. Default 1. |
| `to_currency` | string | yes | `"Japanese Yen"` | Currency to convert to, by name or three-letter code, for example US Dollar or USD. |
| `from_currency` | string | yes | `"euro"` | Currency to convert from, by name or three-letter code, for example euro or EUR. |

## Output

From a run on Oct 23, 2026. Its input:

```json
{
  "date": "2023-06-12",
  "amount": 25,
  "to_currency": "Japanese Yen",
  "from_currency": "euro"
}
```

Its output:

```json
{
  "date": "2023-06-12",
  "rate": 150.1492105901754,
  "to_currency": "JPY",
  "inverse_rate": 0.006660041675007197,
  "from_currency": "EUR",
  "table_page_link": "https://www.xe.com/currencytables/?from=EUR&date=2023-06-12",
  "converted_amount": 3753.73,
  "to_currency_name": "Japanese Yen",
  "from_currency_name": "Euro"
}
```

## Run it

From code, with a Fous API key in `FOUS_API_KEY`; the answer's `data` holds the output:

```bash
curl https://api.fous.com/v1/runs \
  -H "Authorization: Bearer $FOUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"method":"xe.com/get_historical_rate","input":{"date":"2023-06-12","amount":25,"to_currency":"Japanese Yen","from_currency":"euro"}}'
```

From an AI agent connected to the Fous MCP server: its `run` with the same method and input. To connect one, give it `set up https://fous.com/SKILL.md`.

## Ask your agent

- What was the mid-market rate for converting 250 euros to US dollars on 2024-03-08?
- How much were 1000 Japanese yen worth in British pounds on 2023-11-22?
- Look up the XE daily rate from Canadian dollar to Swiss franc for 2022-06-30, amount 500.
- Convert 75 Australian dollars into Indian rupees using the historical rate from 2024-01-15 on xe.com.
- I need the inverse rate and table link for pounds sterling to euro on 2021-09-14 for a 320 GBP conversion.

## Input schema

```json
{
  "type": "object",
  "required": [
    "from_currency",
    "to_currency",
    "date"
  ],
  "properties": {
    "date": {
      "type": "string",
      "description": "Past date of the XE daily UTC table, for example 2024-01-15."
    },
    "amount": {
      "type": "number",
      "default": 1,
      "description": "Amount of the starting currency to convert, for example 100."
    },
    "to_currency": {
      "type": "string",
      "description": "Currency to convert to, by name or three-letter code, for example US Dollar or USD."
    },
    "from_currency": {
      "type": "string",
      "description": "Currency to convert from, by name or three-letter code, for example euro or EUR."
    }
  }
}
```

## Output schema

```json
{
  "type": "object",
  "required": [
    "date",
    "from_currency",
    "from_currency_name",
    "to_currency",
    "to_currency_name",
    "rate",
    "inverse_rate",
    "converted_amount",
    "table_page_link"
  ],
  "properties": {
    "date": {
      "type": "string"
    },
    "rate": {
      "type": "number"
    },
    "to_currency": {
      "type": "string"
    },
    "inverse_rate": {
      "type": "number"
    },
    "from_currency": {
      "type": "string"
    },
    "table_page_link": {
      "type": "string"
    },
    "converted_amount": {
      "type": "number"
    },
    "to_currency_name": {
      "type": "string"
    },
    "from_currency_name": {
      "type": "string"
    }
  }
}
```

## See more

- [XE API: Convert currency](https://fous.com/methods/xe.com/convert-currency.md): Converts an amount between two currencies using XE's displayed mid-market rate. It also returns the rate time and an XE converter link. Rates are informational, not transfer quotes.
- [Wise API: Get exchange rate](https://fous.com/methods/wise.com/get-exchange-rate.md): Gets Wise's current mid-market exchange rate and converted amount for two currencies, with optional daily rate history.
- [European Union API: Convert currency](https://fous.com/methods/ecb.europa.eu/convert-currency.md): Converts an amount between currencies using ECB euro reference rates, including euro and cross-currency conversions. Uses the latest preceding published rate when the date has none.
- [European Union API: Get euro exchange rates](https://fous.com/methods/ecb.europa.eu/get-euro-exchange-rates.md): Gets the official ECB euro reference exchange rates for a day, or the latest published day. Weekends, holidays and dates before publication return the previous published day.
- [Google API: Convert currency amount](https://fous.com/methods/google.com/convert-currency.md): Converts an amount between two currencies using the current Google Finance quote. Rates may be delayed.
- [U.S. Treasury API: Get reporting exchange rates](https://fous.com/methods/treasury.gov/get-reporting-exchange-rates.md): Gets the U.S. Treasury quarterly reporting exchange rate for a country or currency on a given date. If that quarter has no published record, it uses the latest preceding quarter.
- [CoinGecko API: Get coin price on date](https://fous.com/methods/coingecko.com/get-coin-price-on-date.md): Gets a coin's price, market cap and 24-hour volume at 00:00 UTC on a past date. Non-USD currencies are available only for the last 365 days.
- [Internet Archive API: Get archived page](https://fous.com/methods/web.archive.org/get-archived-page.md): Finds the closest Wayback Machine capture of a web page to a past date and returns its title and readable text.
- [All XE methods](https://fous.com/methods/xe.com.md)
