A single historical rate answers “what was EUR/USD on 30 June?”. Charts, backtests, revaluations and warehouse tables need the whole series. The fxapi exchange rate time series API (/v1/range) returns every data point between datetime_start and datetime_end in one call, for as many currencies as you like, at the granularity your use case needs.
Parameters
| Parameter | Required | Description |
|---|---|---|
datetime_start | yes | Start, ISO 8601 – e.g. 2026-01-01T00:00:00Z |
datetime_end | yes | End, ISO 8601 |
accuracy | no | day (default), hour, quarter_hour, minute, week, month |
base_currency | no | Base currency, default USD |
currencies | no | Comma-separated targets – default: all |
type | no | fiat, metal or crypto |
format | no | json (default) or csv |
Full reference: range endpoint docs.
Accuracy, span and look-back
| Accuracy | Data point | Max. span per request | Available back to |
|---|---|---|---|
minute | every minute | 6 hours | last 7 days |
quarter_hour | every 15 minutes | 24 hours | last 7 days |
hour | every hour | 7 days | last 3 months |
day | end of day (UTC) | 366 days | 1999-01-01 |
week | end of week (Sunday) | 1,830 days | 1999-01-01 |
month | end of month | unlimited | 1999-01-01 |
Pick the coarsest accuracy that answers your question: a five-year chart reads better with weekly points, a revaluation needs month-end values, an intraday dashboard wants minutes.
CSV for analysts, JSON for applications
format=csv returns flat rows – datetime,base_currency,currency,value – that load straight into pandas, Excel, Google Sheets, Postgres COPY, BigQuery or Snowflake. JSON returns the same data nested by timestamp for application code. See loading FX data into a warehouse.
Python: 25 years of month-end EUR/USD in one call
import io, os
import pandas as pd
import requests
r = requests.get(
"https://api.fxapi.com/v1/range",
params={
"datetime_start": "2001-01-01T00:00:00Z",
"datetime_end": "2025-12-31T23:59:59Z",
"accuracy": "month",
"base_currency": "EUR",
"currencies": "USD",
"format": "csv",
},
headers={"apikey": os.environ["FXAPI_KEY"]},
timeout=30,
)
r.raise_for_status()
eurusd = pd.read_csv(io.StringIO(r.text), parse_dates=["datetime"])
print(eurusd.tail())
For daily data over more than 366 days, loop year by year – each year is one request. The Python guide has a complete backfill script.
Typical uses
- Charts and widgets – plot currency trends in dashboards and customer-facing apps.
- Revaluation – month-end rates for balance sheet items; combine with average rates for P&L.
- Backtesting and pricing models – consistent daily history since 1999.
- Data warehouses – a daily rates table joined to transactions for constant-currency reporting.
- Volatility checks – feed a series into your own statistics, or get the start/end change directly from the fluctuation API.
Plans
The range endpoint is part of the Professional ($34.99/month, 600,000 requests) and Enterprise ($74.99/month, 1,700,000 requests) plans – see pricing. Need single dates only? The historical exchange rates API is available on every plan, including Free.
This endpoint is part of the fxapi foreign exchange rate API – the same key, response format and 190+ currencies across every endpoint.
Frequently asked questions
How far back does the time series go?
What is the maximum span per request?
Which plan includes the range endpoint?
/v1/historical for individual dates.Does a time series cost one request?
What do weekly and monthly accuracy return?
datetime_end falls inside a period, the last point is the rate at datetime_end.