---
title: "Historical exchange rates for one date | exchangerate.dev"
description: "Fetch past exchange rates from exchangerate.dev with curl, JavaScript and Python examples, a full response, field explanations, error codes and history by plan."
canonical: "https://exchangerate.dev/docs/endpoints/historical"
---

> Index of every exchangerate.dev page and doc for AI readers: [llms.txt](https://exchangerate.dev/llms.txt)

# Request rates for a past date

GET /v1/YYYY-MM-DD: copy a request for rates on one past date

`GET /v1/2026-10-01/USD` returns daily rates from USD for 1 Oct 2026. Free and keyless access covers the last 30 days. Basic includes a year, and Plus reaches back to 1999. Start dates vary by pair.

## Make a request

Use YYYY-MM-DD for the date in the path, followed by the base currency. For a weekend or holiday, the API returns the preceding fix with `is_forward_filled: true`.

```bash
curl "https://api.exchangerate.dev/v1/2026-10-01/USD?symbols=EUR,JPY" \
  -H "Authorization: Bearer $EXCHANGERATE_API_KEY"
```

```javascript
const res = await fetch("https://api.exchangerate.dev/v1/2026-10-01/USD?symbols=EUR,JPY", {
  headers: { Authorization: `Bearer ${process.env.EXCHANGERATE_API_KEY}` },
})
const data = await res.json()
if (data.result !== "success") throw new Error(data.code)
```

```python
import os, requests

res = requests.get(
    "https://api.exchangerate.dev/v1/2026-10-01/USD?symbols=EUR,JPY",
    headers={"Authorization": f"Bearer {os.environ['EXCHANGERATE_API_KEY']}"},
    timeout=10,
)
data = res.json()
if data["result"] != "success":
    raise RuntimeError(data["code"])
```

## Parameters

| Name | Location | Required | Description |
| --- | --- | --- | --- |
| `date` | path, YYYY-MM-DD | Yes | Requested day in UTC |
| `base` | path, or ?base= | No (USD) | Currency used as the base for rates |
| `symbols` | query | No (every other currency) | Currencies to include, separated by commas |

## Read the response

This example was captured without a key on 19 Oct 2026. Historical rates stay the same, but the time fields will change.

```json title="Response example (19 Oct 2026)"
{
  "result": "success",
  "base": "USD",
  "date": "2026-10-01",
  "source": "ecb_daily",
  "sources": {
    "EUR": "ecb_daily",
    "JPY": "ecb_daily"
  },
  "market_session": "open",
  "timestamp": "2026-10-19T12:44:22Z",
  "data_updated_at": "2026-10-01T00:00:00Z",
  "is_forward_filled": false,
  "rates": {
    "EUR": 0.88511,
    "JPY": 157.984
  },
  "derived_symbols": [
    "JPY"
  ],
  "notice": "Indicative rates, not for settlement. Source: incl. public reference data."
}
```

| Field | Description |
| --- | --- |
| `result` | `success` or `error` |
| `source`, `sources` | Rate source: `live`, `ecb_daily` or `market_daily`; `source` reports the least fresh |
| `market_session` | `open`, `weekend` or `interbank_closed` |
| `timestamp` | Time the response was served (UTC) |
| `data_updated_at` | Time of the oldest observation returned (UTC) |
| `date` | Requested day |
| `is_forward_filled` | True if the day had no fix and the preceding fix is returned |
| `rates` | Units of each currency per 1 unit of the base |
| `derived_symbols` | Currencies with rates calculated through another currency |
| `notice` | Indicative-rate reminder and reference-data note |

## Errors

| Status | code | When |
| --- | --- | --- |
| 400 | `bad_date` | Invalid date in YYYY-MM-DD format |
| 403 | `plan_gated` | Date outside your plan's history |
| 429 | `quota_exceeded` | Plan's monthly request limit exceeded |

```json title="Error response"
{
  "result": "error",
  "code": "plan_gated",
  "message": "Your plan includes 30 days of 1d history. Upgrade to the Plus plan.",
  "tier": "free_2026",
  "interval": "1d",
  "history_days": 30,
  "earliest_allowed": "2026-09-19",
  "upgrade_plans": [
    "plus_2026",
    "pro_2026"
  ],
  "upgrade_offers": [
    {
      "plan": "plus_2026",
      "loses": []
    },
    {
      "plan": "pro_2026",
      "loses": []
    }
  ],
  "upgrade_url": "https://exchangerate.dev/pricing?plan=plus_2026&source=api&reason=plan_gated"
}
```

## History available on each plan

Free and keyless access includes the last 30 days. Basic includes the last year, and Plus starts at 1999. A date outside your plan returns 403 with `plan_gated` and `earliest_allowed`. Use `/v1/range` to request a range of dates.

## Questions

### How much exchange rate history is available for free?

The last 30 days, with or without a key. Basic includes a year, and Plus reaches back to 1999.

### What does a request for a weekend date return?

The preceding fix, with is_forward_filled set to true.

### Why did I get plan_gated?

The date falls outside your plan's history. The 403 body includes earliest_allowed and the plans that include the date.

Source: https://exchangerate.dev/docs/endpoints/historical
