Documentation
The Rates API serves the euro foreign exchange reference rates published by the European Central Bank and Banca d'Italia, plus cross-rates for any other base currency.
- Base URL:
https://theratesapi.com/api - No API key or signup. Requests are plain HTTPS
GETs and responses are JSON. - CORS is open, so you can call it from browser JavaScript on any site.
- The ECB publishes around 16:00 CET on working days and Banca d'Italia publishes after it. Where both publish a currency, the ECB's rate is used. Rates for other bases are calculated from them and rounded to 6 decimal places.
GET https://theratesapi.com/api/latest
curl "https://theratesapi.com/api/latest"
const res = await fetch('https://theratesapi.com/api/latest')
const data = await res.json()
import requests
data = requests.get('https://theratesapi.com/api/latest').json()
Latest rates
GET /api/latest returns the newest working day that both banks have published. Until Banca d'Italia publishes, that is the previous working day. If Banca d'Italia hasn't published by midnight UTC, the day appears with the ECB's currencies and the rest are added when it catches up.
Add base to quote against another currency and symbols to return only some of them. See Parameters.
GET https://theratesapi.com/api/latest?base=USD&symbols=GBP,JPY
curl "https://theratesapi.com/api/latest?base=USD&symbols=GBP,JPY"
const res = await fetch('https://theratesapi.com/api/latest?base=USD&symbols=GBP,JPY')
const data = await res.json()
import requests
data = requests.get('https://theratesapi.com/api/latest?base=USD&symbols=GBP,JPY').json()
Response 200
{
"date": "2026-11-13",
"base": "USD",
"rates": {
"GBP": 0.756053,
"JPY": 159.99819
}
}
Historical rates
GET /api/YYYY-MM-DD returns the rates for that day, from 1999-01-04 onwards. Single-digit months and days are accepted, so /api/2025-6-2 works too.
- Weekends and holidays return the previous working day, so check the
datefield in the response. - Future dates return the latest rates.
The same base and symbols parameters apply.
GET https://theratesapi.com/api/2025-06-02?base=USD&symbols=GBP
curl "https://theratesapi.com/api/2025-06-02?base=USD&symbols=GBP"
const res = await fetch('https://theratesapi.com/api/2025-06-02?base=USD&symbols=GBP')
const data = await res.json()
import requests
data = requests.get('https://theratesapi.com/api/2025-06-02?base=USD&symbols=GBP').json()
Response 200
{
"date": "2025-06-02",
"base": "USD",
"rates": {
"GBP": 0.738594
}
}
Parameters
| Name | Default | Description |
|---|---|---|
base | EUR | Currency to quote rates against. Three-letter code, case-insensitive. |
symbols | all | Comma-separated currencies to return, for example USD,GBP. Case-insensitive. Unknown codes are skipped. |
Give each parameter at most once; repeating one returns an error.
GET https://theratesapi.com/api/latest?base=gbp&symbols=usd,inr
curl "https://theratesapi.com/api/latest?base=gbp&symbols=usd,inr"
const res = await fetch('https://theratesapi.com/api/latest?base=gbp&symbols=usd,inr')
const data = await res.json()
import requests
data = requests.get('https://theratesapi.com/api/latest?base=gbp&symbols=usd,inr').json()
Errors
Errors return HTTP 400 with a JSON body containing error.
| When | Status | Body |
|---|---|---|
The date isn't a real calendar date in YYYY-MM-DD form | 400 | Invalid date |
Unknown base, a date before 1999-01-04, or a repeated parameter | 400 | Invalid base or symbols |
Unknown codes in symbols | 200 | Those codes are skipped, so rates can be {} |
Retired currencies such as CYP (Cypriot pound) or SLL (Sierra Leonean leone) still work as base or in symbols for dates when they were published. As the base of /api/latest, they return their last published day.
GET https://theratesapi.com/api/2025-02-30
curl "https://theratesapi.com/api/2025-02-30"
const res = await fetch('https://theratesapi.com/api/2025-02-30')
const data = await res.json()
import requests
data = requests.get('https://theratesapi.com/api/2025-02-30').json()
Response 400
{
"error": "Invalid date"
}
Currencies
The 151 currencies on the latest day. Any of them can be the base.
AEDUAE dirhamAFNAfghan afghaniALLAlbanian lekAMDArmenian dramAOAAngolan kwanzaARSArgentine pesoAUDAustralian dollarAWGAruban florinAZNAzerbaijani manatBAMBosnia and Herzegovina convertible markBBDBarbados dollarBDTBangladeshi takaBHDBahraini dinarBIFBurundian francBMDBermudian dollarBNDBrunei dollarBOBBolivian bolivianoBRLBrazilian realBSDBahamian dollarBTNBhutanese ngultrumBWPBotswana pulaBZDBelize dollarCADCanadian dollarCDFCongolese francCHFSwiss francCLPChilean pesoCNYChinese yuan renminbiCOPColombian pesoCRCCosta Rican colónCUPCuban pesoCVECape Verdean escudoCZKCzech korunaDJFDjiboutian francDKKDanish kroneDOPDominican pesoDZDAlgerian dinarEGPEgyptian poundERNEritrean nakfaETBEthiopian birrEUREuroFJDFiji dollarFKPFalkland Islands poundGBPPound sterlingGELGeorgian lariGHSGhanaian cediGIPGibraltar poundGMDGambian dalasiGNFGuinean francGTQGuatemalan quetzalGYDGuyanese dollarHKDHong Kong dollarHNLHonduran lempiraHTGHaitian gourdeHUFHungarian forintIDRIndonesian rupiahILSIsraeli shekelINRIndian rupeeIQDIraqi dinarISKIcelandic kronaJMDJamaican dollarJODJordanian dinarJPYJapanese yenKESKenyan shillingKGSKyrgyz somKHRCambodian rielKMFComorian francKRWSouth Korean wonKWDKuwaiti dinarKYDCayman Islands dollarKZTKazakhstani tengeLAKLao kipLBPLebanese poundLKRSri Lankan rupeeLRDLiberian dollarLSLLesotho lotiLYDLibyan dinarMADMoroccan dirhamMDLMoldovan leuMGAMalagasy ariaryMKDMacedonian denarMMKMyanmar kyatMNTMongolian tugrikMOPMacanese patacaMRUMauritanian ouguiyaMURMauritian rupeeMVRMaldivian rufiyaaMWKMalawian kwachaMXNMexican pesoMYRMalaysian ringgitMZNMozambican meticalNADNamibian dollarNGNNigerian nairaNIONicaraguan córdobaNOKNorwegian kroneNPRNepalese rupeeNZDNew Zealand dollarOMROmani rialPABPanamanian balboaPENPeruvian solPGKPapua New Guinean kinaPHPPhilippine pesoPKRPakistani rupeePLNPolish zlotyPYGParaguayan guaraníQARQatari riyalRONRomanian leuRSDSerbian dinarRWFRwandan francSARSaudi riyalSBDSolomon Islands dollarSCRSeychellois rupeeSDGSudanese poundSEKSwedish kronaSGDSingapore dollarSHPSaint Helena poundSLESierra Leonean leoneSOSSomali shillingSRDSurinamese dollarSSPSouth Sudanese poundSTNSão Tomé and Príncipe dobraSVCSalvadoran colónSYPSyrian poundSZLSwazi lilangeniTHBThai bahtTJSTajikistani somoniTMTTurkmenistani manatTNDTunisian dinarTOPTongan pa'angaTRYTurkish liraTTDTrinidad and Tobago dollarTWDNew Taiwan dollarTZSTanzanian shillingUAHUkrainian hryvniaUGXUgandan shillingUSDUS dollarUYUUruguayan pesoUZSUzbekistani somVESVenezuelan bolívar soberanoVNDVietnamese dongVUVVanuatu vatuWSTSamoan talaXAFCentral African CFA francXCDEast Caribbean dollarXCGCaribbean guilderXDRIMF special drawing rightsXOFWest African CFA francXPFCFP francYERYemeni rialZARSouth African randZMWZambian kwachaZWGZimbabwe gold
Fair use
There are no keys or rate limits today. Help keep it that way:
- Cache responses. Rates change once per working day, and responses carry
Cache-Control: public, max-age=300. - Don't request more often than you need to. Traffic that harms the service for others may be blocked.
The service comes with no warranty. See the terms of use.