Bank of Uganda Exchange Rate API: Official UGX Rates as JSON
The Bank of Uganda publishes the official exchange rates that accounting, tax, and customs practice in Uganda reference — published official rates, not moving market prices. This guide shows how to pull them as JSON: via a REST endpoint or the zero-dependency bou-exchange-rate npm package.
The daily rate card, majors and COMESA both
The BoU issues an opening rate card each morning: middle, buying and selling shilling rates for the major world currencies — gold included — plus a COMESA table covering the regional currencies from Kenyan shillings to Ethiopian birr and South Sudanese pounds. The middle rate is what Ugandan banks and the revenue authority work from, and the API serves both tables under one endpoint.
Why official rates, not market rates
A live mid-market feed answers "what is USD/UGX trading at right now?" — the right tool for checkouts and dashboards. But accountants, auditors, and tax authorities ask a different question: "which rate were you required to use for this date?" That answer comes from the Bank of Uganda’s published rates, and it never changes after publication.
Get the latest rates (REST)
curl "https://allratestoday.com/api/v1/central-bank/bou/latest" \
-H "Authorization: Bearer YOUR_API_KEY" The response is the bank's most recent published table — every rate and the publication date. The latest rates are available on every plan, including the free tier (300 requests/month, no credit card).
The npm SDK
npm install bou-exchange-rate import { getRate, getLatestRates } from 'bou-exchange-rate';
// One pair at the official rate
const pair = await getRate('USD', 'UGX', { apiKey: 'art_live_...' });
console.log(pair.rate, pair.rate_date);
// The bank's full published table
const table = await getLatestRates({ apiKey: 'art_live_...' });
console.log(table.rate_date, table.rates.length); Zero dependencies, TypeScript types included, and it runs anywhere fetch exists — Node 18+, Bun, Deno, and edge runtimes.
Historical rates for an invoice date
import { getRatesForDate, getHistory } from 'bou-exchange-rate';
const day = await getRatesForDate('2026-08-18', { apiKey: 'art_live_...' });
const series = await getHistory(
{ source: 'USD', target: 'UGX', from: '2026-01-01' },
{ apiKey: 'art_live_...' }
); Historical dates and time series need a paid plan; the latest rates stay free.
Published vs derived pairs
If the Bank of Uganda does not print a pair directly, the API resolves it from the bank's published rates — an inverse, or a cross via UGX — and flags it derived: true with the method used. Official and computed values are never silently mixed, which is exactly the distinction an auditor will ask about.
The archive
The bank’s old statistics archive is no longer online, so the API’s archive builds forward from ingestion — each day’s card is captured as published.
FAQ
Does the Bank of Uganda have an official exchange rate API?
The bank publishes its official rates on its own site, and AllRatesToday serves the same published rates as clean JSON via REST or the bou-exchange-rate npm package. The latest table is free.
How do I get the official Uganda exchange rate for a past date?
The rates-for-date endpoint returns the official table for any archived date; non-publication days resolve to the most recent published date and are flagged, so audit trails stay honest. Historical dates require a paid plan; latest rates are free.
Does the API include the COMESA cross rates?
Yes — the rate card's second table (Kenyan and Tanzanian shillings, Rwandan and Burundian francs, birr, South Sudanese pound and more) is served alongside the majors, all normalised to shillings per unit.
Official Bank of Uganda rates, as JSON
The latest rates are free — 300 requests/month, no credit card.
Get your free API key