Getting started overview
Frankfurter offers a straightforward API for retrieving current and historical foreign exchange rates. Designed for simplicity, it allows developers to integrate currency data without complex authentication processes. The service provides daily updated rates for a comprehensive list of currencies, and historical data extending back one year, all accessible through its free tier.
This guide focuses on the initial steps to make your first functional request to the Frankfurter API. It covers accessing the API without an API key, understanding the basic endpoint structure, and executing a simple query to retrieve exchange rates.
Frankfurter Getting Started Quick Reference:
| Step | What to Do | Where |
|---|---|---|
| 1. Review Authentication | Understand that no API key is needed for basic access. | Frankfurter API documentation |
| 2. Identify Base URL | Note the API base URL: https://api.frankfurter.app |
Frankfurter API reference |
| 3. Choose an Endpoint | Select a basic endpoint, e.g., /latest for current rates. |
Frankfurter API endpoints |
| 4. Construct Request | Formulate your first HTTP GET request. | See Your first request section below |
| 5. Execute Request | Use a browser, curl, or a client library to send the request. |
Your preferred development environment |
| 6. Parse Response | Interpret the JSON response data. | See Your first request section below |
Create an account and get keys
Unlike many other APIs, Frankfurter does not require an API key or account creation for basic access to its core functionality. This design choice simplifies the initial integration process, allowing developers to start querying exchange rates immediately. The API is publicly accessible through its base URL.
Developers can send HTTP GET requests directly to the Frankfurter API endpoints without needing to register, sign in, or manage credentials. This approach supports rapid prototyping and integration for applications that do not require advanced features, higher rate limits, or extensive historical data beyond the free tier's offerings. For those accustomed to setting up authentication, the absence of keys means direct access.
Your first request
To make your first request, you will use the /latest endpoint, which provides the most recent exchange rates. This endpoint requires no parameters for a basic call, returning rates relative to the Euro (EUR) by default. The response format is JSON.
1. Base URL
All requests to the Frankfurter API begin with the base URL: https://api.frankfurter.app.
2. Endpoint: Get Latest Rates
To fetch the latest exchange rates, append /latest to the base URL:
GET https://api.frankfurter.app/latest
3. Making the Request
You can make this request using a web browser, curl from your terminal, or an HTTP client library in your preferred programming language.
Using curl:
Open your terminal or command prompt and execute:
curl https://api.frankfurter.app/latest
Expected JSON Response:
A successful request will return a JSON object similar to this (values will vary based on current rates):
{
"amount": 1,
"base": "EUR",
"date": "2026-05-29",
"rates": {
"AUD": 1.6384,
"BGN": 1.9558,
"BRL": 5.5673,
"CAD": 1.472,
"CHF": 0.9818,
"CNY": 7.8288,
"CZK": 24.872,
"DKK": 7.461,
"GBP": 0.8524,
"HKD": 8.4485,
"HUF": 394.3,
"IDR": 17534.6,
"ILS": 3.9961,
"INR": 90.737,
"ISK": 148.9,
"JPY": 170.15,
"KRW": 1478.07,
"MXN": 18.252,
"MYR": 5.0934,
"NOK": 11.6665,
"NZD": 1.7925,
"PHP": 63.639,
"PLN": 4.3168,
"RON": 4.976,
"SEK": 11.2335,
"SGD": 1.4589,
"THB": 39.734,
"TRY": 35.197,
"USD": 1.0837,
"ZAR": 20.015
}
}
This response indicates that 1 Euro ("base": "EUR") is equivalent to 1.0837 US Dollars ("USD": 1.0837), 0.8524 Great British Pounds ("GBP": 0.8524), and so on, for the given date.
Optional Parameters: Specify Base and Target Currencies
You can customize your request by specifying a different base currency and target currencies. For example, to get the latest rates for USD to JPY and GBP:
GET https://api.frankfurter.app/latest?from=USD&to=JPY,GBP
Using curl:
curl "https://api.frankfurter.app/latest?from=USD&to=JPY,GBP"
Note: The "USD" in the from parameter and "JPY,GBP" in the to parameter are standard URI component encoding practice for query strings. The Frankfurter API handles this directly.
Common next steps
After successfully making your first request, consider these common next steps to expand your integration:
-
Explore Historical Rates: The Frankfurter API allows you to retrieve historical exchange rates for specific dates or date ranges. Use the
/{date}endpoint or date range endpoints like/{start}..{end}to fetch past data. This is useful for analytics or calculating past transaction values. Details are available in the Frankfurter API documentation. -
List Available Currencies: To discover all supported currencies, make a request to the
/currenciesendpoint. This returns a JSON object listing currency codes and their full names, which can be useful for dynamic user interfaces or input validation within your application. For example, a request tohttps://api.frankfurter.app/currencieswill return a list of available currencies. -
Error Handling: Implement robust error handling in your application. The Frankfurter API typically returns standard HTTP status codes (e.g., 400 for bad requests, 404 for not found) and a JSON error message when issues occur. Understanding these responses helps in debugging and providing meaningful feedback to users.
-
Rate Limits and Usage Patterns: While Frankfurter doesn't explicitly detail rate limits for its free tier, it's good practice to implement reasonable request intervals to avoid potential service disruptions. For applications requiring high-frequency updates or very large volumes of historical data, consider alternative services that offer dedicated plans for such use cases.
-
Client Libraries: For more complex applications, consider using an HTTP client library in your programming language (e.g., Python's
requests, JavaScript'sfetch, Java'sHttpClient) to manage requests, parse JSON, and handle errors more efficiently. These libraries often provide abstractions that simplify API interactions, for example, the Fetch API documentation provides guidance for web-based requests.
Troubleshooting the first call
If your first call to the Frankfurter API doesn't return the expected results, consider the following common issues and solutions:
-
Incorrect URL: Double-check the base URL and endpoint path. A common mistake is typos in
https://api.frankfurter.app/latest. Ensure there are no extra spaces or incorrect characters. -
Network Issues: Verify your internet connection. If you are behind a firewall or proxy, ensure it allows outgoing HTTP/HTTPS requests to
api.frankfurter.app. Tools likepingortraceroutecan help diagnose network connectivity problems. -
HTTP Method: The Frankfurter API primarily uses GET requests for retrieving data. Ensure you are not attempting to use POST, PUT, or DELETE methods, which are not supported for data retrieval endpoints.
-
Parameter Formatting: When adding query parameters like
fromandto, ensure they are correctly formatted. Parameters should be separated by&, and values should be URL-encoded if they contain special characters (though currency codes typically do not). For example:?from=USD&to=JPY,GBP. -
JSON Parsing Errors: If you receive a response but your application fails to parse it, ensure your JSON parsing library is correctly configured. Verify that the response is indeed valid JSON by pasting it into an online JSON validator. The Frankfurter API always returns valid JSON for successful responses.
-
API Documentation Review: Refer to the official Frankfurter API documentation for the most up-to-date information on endpoints, parameters, and expected responses. This resource is the definitive source for API behavior.
-
HTTP Status Codes: Pay attention to the HTTP status code returned with the response. A
200 OKindicates success. Other codes, such as400 Bad Requestor404 Not Found, point to specific issues that can guide your troubleshooting. For example, a400might indicate an invalid currency code in your request.