Frankfurter
Frankfurter tracks daily exchange rates from 30+ central banks and official sources, covering 160 active currencies.
The public API lives at api.frankfurter.dev. No keys. Use anywhere. You can also self-host.
Rates
Fetch the latest exchange rates.
curl https://api.frankfurter.dev/v2/rates Change the base currency with base. Filter target currencies with quote.
curl https://api.frankfurter.dev/v2/rates?base=USD"es=EUR,GBPHistorical Rates
Look up rates for a specific date.
curl https://api.frankfurter.dev/v2/rates?date=1999-01-04Time Series
Fetch rates over a period with from and to.
curl https://api.frankfurter.dev/v2/rates?from=2024-01-01&to=2024-01-05"es=USDTip: Narrowing down currencies keeps responses small. For large date ranges, request NDJSON to stream results line by line.
Grouping
Downsample a time series with group.
curl https://api.frankfurter.dev/v2/rates?from=2024-01-01&group=monthFiltering by Provider
Scope to specific providers with providers.
curl https://api.frankfurter.dev/v2/rates?providers=ECB By default, rates are blended across all providers. Use providers to retrieve rates from a specific source.
CSV Output
Rates are also available as CSV. Append .csv to the path or set the Accept header to text/csv.
curl https://api.frankfurter.dev/v2/rates.csvNDJSON Output
For large responses, request NDJSON (newline-delimited JSON) by setting the Accept header to application/x-ndjson. Each line is one independent JSON object, useful for streaming large time series without buffering the entire response.
curl -H "Accept: application/x-ndjson" \
"https://api.frankfurter.dev/v2/rates?from=2024-01-01"Rate
Get the rate for a single currency pair. Optionally add date or providers.
curl https://api.frankfurter.dev/v2/rate/EUR/USDCurrency
Get details and provider coverage for a single currency.
curl https://api.frankfurter.dev/v2/currency/EURCurrencies
Get available currencies with provider coverage.
curl https://api.frankfurter.dev/v2/currenciesProviders
List the data sources behind the API.
curl https://api.frankfurter.dev/v2/providersConversion
Fetch the rate and convert in your own code.
function convert(base, quote, amount) {
fetch(`https://api.frankfurter.dev/v2/rates?base=${base}"es=${quote}`)
.then((resp) => resp.json())
.then((data) => {
const result = (amount * data[0].rate).toFixed(2);
alert(`${amount} ${base} = ${result} ${quote}`);
});
}
convert("EUR", "USD", 10);Click or tap the snippet to run it.
Errors
The API returns standard HTTP status codes with a JSON body.
{
"message": "Could not find currency ABC"
}400- Invalid parameter or malformed request.
404- Currency, rate, or resource not found.
422- Request understood but cannot be processed.
Self-Hosting
You can self-host with Docker. See the deploy guide for production setup and API key configuration.
FAQ
- Is the API free for commercial use?
- Yes, absolutely.
- Does the API have any call limits?
- There are no limits. For high-volume use, consider caching responses or self-hosting.
- Is the v1 API being retired?
- No. The v1 API will continue to work. See the v1 documentation.
- What is the privacy policy of the API?
- The API itself does not collect personal data. However, the public app runs behind Cloudflare for performance, and Cloudflare will collect some basic information for analytics. This does not apply if you run the API privately.
- Can I suggest a new data source?
- If you know of a provider we should add, please open an issue and include a link to the source. We're looking for non-commercial sources that publish current and historical rates at least daily.
- How accurate are the rates?
- It depends on your use case. If you need official reference rates for reporting or compliance, filter by a specific provider. The numbers will match what that institution publishes. If you're converting prices for display, say, localizing an e-commerce site, the default blended rates work well. They're drawn from multiple sources and are accurate for practical use, though the last decimal places may shift slightly as new data comes in.
- Why is it called Frankfurter?
- Frankfurt is home to the European Central Bank, the original data source of this project.