Skip to content
US Dollar · USD

US dollar (USD) exchange rate API

USD is the default base_currency in fxapi: every request without a base returns rates per 1 US dollar. Live, historical and average USD rates against 190+ currencies.

CodeUSD
Symbol$
Decimals2
HistorySince 1999
GET /v1/latest · base USD
curl -G "https://api.fxapi.com/v1/latest" \
  -d base_currency=USD \
  -d currencies=EUR,JPY,GBP,CNY \
  -H "apikey: $FXAPI_KEY"
# USD on a past date
curl -G "https://api.fxapi.com/v1/historical" \
  -d date=2008-09-15 -d base_currency=USD \
  -d currencies=EUR \
  -H "apikey: $FXAPI_KEY"
ISO 4217 codeUSD
Symbol$
Minor unit2 decimals
IssuerFederal Reserve

The US dollar is the currency most foreign exchange trades are quoted against, the main invoicing currency for commodities and a large share of cross-border trade, and the largest component of global central bank reserves. For a developer that has one practical consequence: when you need a rate between two other currencies, it is usually derived through the dollar. The fxapi USD exchange rate API reflects that – USD is the default base_currency, and you can switch to any other base when you need cross rates such as EUR/JPY (see base currency and cross rates).

USD facts for developers

  • Where it’s used: the United States and its territories, plus several countries that use the dollar as their official currency, including Ecuador (since 2000), El Salvador (since 2001), Timor-Leste, the Marshall Islands, Micronesia and Palau. Panama uses it alongside the balboa (PAB), which is fixed at par.
  • Symbol and formatting: $ before the amount, comma as thousands separator, period as decimal separator: $1,234.56. The $ sign is shared with CAD, AUD, MXN and many other dollars and pesos, so multi-currency UIs should show US$ or the ISO code.
  • Minor unit: 2 decimals (cents).
  • Central bank: the Federal Reserve System sets US monetary policy.
  • Pegs to the dollar: several currencies are fixed or tightly managed against USD, including the HKD, AED and SAR. Their USD rates move very little; their rates against everything else move with the dollar.
  • Events in the historical data: the dollar rose against most currencies in the second half of 2008 – the default sample date on this page, 2008-09-15, is the day Lehman Brothers filed for bankruptcy – and it rallied again during the March 2020 market sell-off.

Get USD rates with the fxapi API

/v1/latest and /v1/historical return rates per 1 USD on every plan, including Free. If you want converted amounts rather than unit rates, /v1/convert (Basic plan and up) multiplies for you and accepts an optional date. This Python snippet converts a USD invoice into four currencies today and at a past date:

import os
import requests

API = "https://api.fxapi.com/v1"
HEADERS = {"apikey": os.environ["FXAPI_KEY"]}

def convert_usd(amount, targets, date=None):
    params = {"base_currency": "USD", "currencies": ",".join(targets), "value": amount}
    if date:
        params["date"] = date
    r = requests.get(f"{API}/convert", params=params, headers=HEADERS, timeout=10)
    r.raise_for_status()
    return {code: item["value"] for code, item in r.json()["data"].items()}

print(convert_usd(2500, ["EUR", "GBP", "JPY", "MXN"]))
print(convert_usd(2500, ["EUR", "GBP"], date="2008-09-15"))

More Python patterns – retries, caching, pandas – are in the exchange rate API Python guide. Plan limits are on the pricing page.

Things to watch

  • Don’t invert twice. Without base_currency, values are per 1 USD. If your code divides by the rate to get “USD per unit”, make sure no other layer does the same.
  • Round late. Keep full precision while converting and round to the target currency’s minor unit only for display or settlement – JPY and KRW have 0 decimals, most others 2. See currency rounding and precision.
  • Pegged pairs look flat. Don’t flag tiny USD/HKD or USD/SAR moves as anomalies; flag them if they leave the official band.

Popular USD pairs

Request any of these pairs – or any other combination of the 190+ supported currencies – with base_currency=USD:

PairLatest rate request
USD/EUR/v1/latest?base_currency=USD&currencies=EUR
USD/JPY/v1/latest?base_currency=USD&currencies=JPY
USD/GBP/v1/latest?base_currency=USD&currencies=GBP
USD/CNY/v1/latest?base_currency=USD&currencies=CNY
USD/CAD/v1/latest?base_currency=USD&currencies=CAD
USD/MXN/v1/latest?base_currency=USD&currencies=MXN
USD/CHF/v1/latest?base_currency=USD&currencies=CHF
USD/INR/v1/latest?base_currency=USD&currencies=INR

Monthly averages and fluctuation for USD

# Monthly average USD rates for 2025 (IAS 21 / ASC 830)
curl -G "https://api.fxapi.com/v1/average" \
  -d date_from=2025-01-01 -d date_to=2025-12-31 -d period=month \
  -d base_currency=USD -d currencies=EUR,JPY,GBP \
  -H "apikey: $FXAPI_KEY"

# How did USD move over the last year?
curl -G "https://api.fxapi.com/v1/fluctuation" \
  -d date_from=2025-10-01 -d date_to=2026-10-01 \
  -d base_currency=USD -d currencies=EUR,JPY,GBP \
  -H "apikey: $FXAPI_KEY"

See the historical exchange rates API, average rates API and documentation for every parameter.

USD is one of 190+ currencies in fxapi, the FX rates API for developers – live rates, daily history since 1999 and monthly averages with one API key.

Frequently asked questions

How do I get USD exchange rates via API?
Call GET /v1/latest with your key in the apikey header. USD is the default base, so every value is the amount of the target currency per 1 USD. Add currencies=EUR,JPY to return only the pairs you need.
How do I get the USD to EUR rate for a past date?
Use /v1/historical?date=2015-06-30&currencies=EUR. It returns the end-of-day (UTC) rate for that date. See the historical exchange rates API.
Does fxapi have historical USD rates before 1999?
No. Daily data starts on 1999-01-01, so the earliest date you can request is 1999-01-01.
Can I convert an amount from USD directly?
Yes. /v1/convert?value=2500&currencies=EUR,GBP returns converted amounts instead of unit rates. The convert endpoint is available on the Basic plan and above.
Which currencies are pegged to the US dollar?
Among others the Hong Kong dollar (7.75–7.85 band), the UAE dirham (3.6725) and the Saudi riyal (3.75). Their USD rates barely move, which makes them useful sanity checks.
Free plan · no credit card

Get your free exchange rate API key

300 requests a month, latest and historical rates, fluctuation and averages – free forever. Upgrade when you need faster updates or more requests.