Bank of China Exchange Rate API: CNY Buy and Sell Rates as JSON
Bank of China is one of China’s four large state-owned banks and its oldest foreign-exchange bank. Its board lists spot-exchange and cash buy/sell rates plus a middle rate for about 34 currencies, quoted per 100 units of foreign currency, with a publication time on each row. This guide shows how to read that board as JSON: what the rates mean, how they compare with the People’s Bank of China official rate and with other banks in China, and the calls that return them.
What the Bank of China board shows
- 34 currencies against the Chinese yuan: AED, AUD, CAD, CHF, DKK, EUR, GBP, HKD, HUF, IDR, JPY, KRW, KZT, MNT, MOP, MUR, MXN, MYR, NOK, NZD, PHP, PLN, QAR, RON, RSD, RUB, SAR, SEK, SGD, THB, TRY, USD, ZAR and ZMW. Every value is CNY per 1 unit of the foreign currency.
- The spot exchange (transfer) buy / sell pair. The People’s Bank of China sets a daily central parity for the yuan, but the rate a customer gets is a bank’s board, and Bank of China’s is the one most quoted. Chinese banks publish spot-exchange (transfer) and cash columns, quoted per 100 units of foreign currency; the pair here is spot exchange, shown per 1 unit.
- USD on 13 November 2026: Bank of China bought at 6.6612 and sold at 6.6892 CNY, a spread of 0.42%. The People’s Bank of China official rate was 6.7152, so the bank's mid sat -0.60% from it.
- The bank's own timestamp. The page prints a last-updated stamp (
2026/11/13 21:33:40 (Beijing)on the board above), returned asbank_updated_atnext to ourcaptured_at. - Every day's board is kept permanently, from 20 October 2026. Read one past day with
?date=, or a range for one currency with the/historyendpoint (paid plans).
Spreads across the board
On the 13 November 2026 board the tightest spreads were HKD (0.40%), USD (0.42%), MOP (0.46%) and the widest ZMW (22.00%), MUR (22.00%), QAR (22.00%). Spread is (sell − buy) ÷ mid: what a round trip through the bank costs, before any fees. The API returns it on every row as spread_pct, so you can rank currencies or alert when a bank widens its board.
USD at Bank of China and other banks in China
USD on the 3 boards AllRatesToday reads in China, all captured on 13 November 2026 (the People’s Bank of China official rate was 6.7152):
| Bank | Buy | Sell | Spread | Mid vs official |
|---|---|---|---|---|
| Bank of China | 6.6612 | 6.6892 | 0.42% | -0.60% |
| Industrial and Commercial Bank of China | 6.6531 | 6.6878 | 0.52% | -0.67% |
| China Construction Bank | 6.6558 | 6.6905 | 0.52% | -0.63% |
Bank of China had the narrowest USD spread of the 3. One call to /api/v1/bank-rates/cn returns every board in the table at once.
Get the board (REST)
You need an API key; the free key works. The full board:
curl "https://allratestoday.com/api/v1/bank-rates/cn/boccn" \
-H "Authorization: Bearer art_live_your_key" What comes back (the 13 November 2026 board, first three rows):
{
"bank": "boccn",
"name": "Bank of China",
"country": "cn",
"quote_ccy": "CNY",
"bank_updated_at": "2026/11/13 21:33:40 (Beijing)",
"basis": "Spot exchange (transfer) buy / sell",
"captured_at": "2026-11-13T13:35:59.914Z",
"rates": [
{"ccy":"AED","buy":1.804,"sell":1.8294,"mid":1.8167,"spread_pct":1.398,"official":1.8227220531141208,"vs_official_pct":-0.33},
{"ccy":"AUD","buy":4.5223,"sell":4.5582,"mid":4.54025,"spread_pct":0.791,"official":4.5575,"vs_official_pct":-0.378},
{"ccy":"CAD","buy":4.6672,"sell":4.7039,"mid":4.68555,"spread_pct":0.783,"official":4.6947,"vs_official_pct":-0.195},
… 31 more currencies
],
"disclaimer": "…",
"attribution": { … }
} One currency, with the row fields at the top level:
curl "https://allratestoday.com/api/v1/bank-rates/cn/boccn?ccy=USD" \
-H "Authorization: Bearer art_live_your_key" {
"bank": "boccn",
"name": "Bank of China",
"country": "cn",
"quote_ccy": "CNY",
"bank_updated_at": "2026/11/13 21:33:40 (Beijing)",
"basis": "Spot exchange (transfer) buy / sell",
"captured_at": "2026-11-13T13:35:59.914Z",
"ccy": "USD",
"buy": 6.6612,
"sell": 6.6892,
"mid": 6.6752,
"spread_pct": 0.419,
"official": 6.7152,
"vs_official_pct": -0.596,
"disclaimer": "Retail buy/sell rates as displayed on each bank’s own website at capture time, quoted as home currency per 1 unit of foreign currency. Indicative only: banks change these through the day, apply them at the counter or in-app, and they are not official or reference rates. For the rate a regulation names, use the central-bank endpoints.",
"attribution": {
"source": "Board rates published by Bank of China on its own website, collected by AllRatesToday",
"bank_url": "https://www.boc.cn/sourcedb/whpj/enindex_1619.html",
"url": "https://allratestoday.com/bank-exchange-rate-api/cn/boccn/",
"terms": "Public pages that show the rates need a visible link to allratestoday.com"
}
} The board as it stood on a past day:
curl "https://allratestoday.com/api/v1/bank-rates/cn/boccn?date=2026-11-06" \
-H "Authorization: Bearer art_live_your_key" One currency over a date range, one row per day (paid plans; add &format=csv, xml or xlsx for a file):
curl "https://allratestoday.com/api/v1/bank-rates/cn/boccn/history?ccy=USD&from=2026-10-20&to=2026-11-13" \
-H "Authorization: Bearer art_live_your_key" JavaScript
npm install @allratestoday/sdk import { AllRatesToday } from '@allratestoday/sdk';
const client = new AllRatesToday({ apiKey: 'art_live_your_key' });
// Bank of China's USD row
const r = await client.bankRates('cn', { bank: 'boccn', ccy: 'USD' });
console.log(`Bank of China buys USD at ${r.buy}, sells at ${r.sell} CNY`);
// The board as it stood on a past day
const past = await client.bankRates('cn', { bank: 'boccn', date: '2026-11-06' });
console.log(past.snapshot_date, past.rates.length); Python
import requests
r = requests.get(
"https://allratestoday.com/api/v1/bank-rates/cn/boccn",
headers={"Authorization": "Bearer art_live_your_key"},
timeout=10,
)
r.raise_for_status()
for row in r.json()["rates"]:
print(row["ccy"], row["buy"], row["sell"], row["spread_pct"]) Board rate or official rate?
The People’s Bank of China rate is the one tax, accounting and customs rules in China name; nobody transacts at it. Bank of China's board is the price a customer actually gets. The API puts both on every row: official is the central bank's rate for the same currency and vs_official_pct is how far the bank's mid sits from it. Use the board to show customers a real price, compare banks for a remittance, or keep a dated record of what the bank quoted; use the People’s Bank of China endpoint when a rule asks for the official rate.
FAQ
Where do the Bank of China rates come from?
From the bank's own public rates page (https://www.boc.cn/sourcedb/whpj/enindex_1619.html), read hourly. AllRatesToday does not change the numbers: each row is the buy and sell price Bank of China shows, with the mid, the spread and the People’s Bank of China rate added.
Are these the official CNY exchange rates?
No. They are Bank of China's retail prices for customers. The official rate in China is the People’s Bank of China rate, which the API returns as official on each row where the central bank has one, and in full from the central-bank endpoint.
How often is the Bank of China board updated?
AllRatesToday reads the page every hour. The bank's own last-updated stamp is returned as bank_updated_at, so you can tell a fresh read of an unchanged board from a new board.
Can I get Bank of China rates for a past date?
Yes, from 20 October 2026 onward; every day's board is kept permanently. Add ?date=YYYY-MM-DD for one day: the response is the board captured that day, or the nearest earlier day within five days, with date_requested and snapshot_date added. For a range, /history?ccy=USD&from=…&to=… returns one row per day as JSON, CSV, XML or XLSX on paid plans.
Do I need an API key?
Yes. Commercial bank boards need an API key; any plan works, the free key included, and each call counts against the plan. Public pages or widgets that show the rates need a visible link to allratestoday.com.
Bank of China rates, as JSON
Free API key, hourly board captures, the official rate alongside.
Get your free API key