Bank of Canada Interest Rate API
The Bank of Canada sets the target for the overnight rate, the policy rate that anchors Canadian short-term interest rates and mortgage lending. BoC decisions are particularly sensitive to housing, oil prices, and US monetary policy spillover, and they move the Canadian Dollar (CAD) against the USD on every announcement. The Bank of Canada Interest Rate API provides current and historical overnight rate data through a single REST endpoint.
The Bank of Canada Interest Rate API allows you to:
- Get the current BoC policy interest rate
- Fetch historical BoC rate data over any time range
- Access rate data updated every 4 hours via a simple REST API
From 3,856 users
Applications using this API
API Status
API Response Times
Average | P50 | P75 | P90 | P95 |
|---|---|---|---|---|
| 328ms | 370ms | 381ms | 718ms | 999ms |
Didn't find what you were looking for? Suggest an improvement
/v2/interestrate GETPremium only
https://api.api-ninjas.com/v2/interestrate
Returns the current Bank of Canada interest rate, including the rate name and the date the rate was last updated.
Parameters
raterequiredName of the interest rate to retrieve. Use
central_bank_cafor the Bank of Canada. See the full list of supported rates.
Headers
X-Api-KeyrequiredAPI Key associated with your account.
Response
A JSON object with the following fields or an error if the request is unsuccessful.
rate_nameThe name of the interest rate (e.g.
Bank of Canada).rate_pctThe interest rate value as a percentage.
last_updatedDate when the rate was last updated (MM-DD-YYYY format).
Sample Request Live Demo!
Get a free API key to get started — no credit card required.
Code Examples
curl -X GET "https://api.api-ninjas.com/v2/interestrate?rate=central_bank_ca" \
-H "X-Api-Key: YOUR_API_KEY"If your programming language is not listed above, you can still make API calls by using any HTTP request library and following the documentation above.
/v2/interestratehistorical GETPremium only
https://api.api-ninjas.com/v2/interestratehistorical
Returns historical Bank of Canada interest rates. You can specify a time range to retrieve data from. The maximum number of data points returned per API call is 100.
Parameters
raterequiredUse
central_bank_cafor the Bank of Canada.start_timeoptionalStart time for the data range, specified as a UNIX timestamp in seconds.
end_timeoptionalEnd time for the data range, specified as a UNIX timestamp in seconds.
Headers
X-Api-KeyrequiredAPI Key associated with your account.
Response
A JSON object with the following fields or an error if the request is unsuccessful.
nameThe name of the interest rate (e.g.
Bank of Canada).dataArray of historical rate data objects, each containing
timestamp(UNIX timestamp in seconds) andrate_pct(interest rate as a percentage).
Sample Request Live Demo!
Get a free API key to get started — no credit card required.
Code Examples
curl -X GET "https://api.api-ninjas.com/v2/interestratehistorical?rate=central_bank_ca" \
-H "X-Api-Key: YOUR_API_KEY"Frequently Asked Questions
Can I use the Interest Rate API for commercial purposes?
Yes, but you must have a premium subscription. Commercial use of the Interest Rate API is not permitted on the free tier. See our pricing page to choose a plan that fits your needs.How do I get an API key and start using the Interest Rate API?
Sign up for a free account to instantly get your API key, then pass it in theX-Api-Keyheader on every request. The documentation above includes ready-to-run examples in cURL, Python, JavaScript, Node.js, and more.What happens if I exceed my quota for the month?
Your API requests will simply be denied once you hit your monthly quota — you will never be charged more than the plan you signed up for. To increase your quota, you can upgrade your plan any time on our pricing page.What happens if a request to the Interest Rate API fails?
The API responds with a standard HTTP status code and a JSON error message describing the problem. See our error codes reference for the full list of codes and how to resolve each one, or contact support if you need help.What rates can I retrieve with the Interest Rate API?
The API covers current central bank policy rates for 22 countries plus major benchmark and prime rates, including SOFR, EURIBOR, ESTER, SONIA, SARON, TONAR, CORRA, EFFR, and Livret A, all queried via therateparameter on the/v2/interestrateendpoint. For LIBOR-specific tooling see the LIBOR API, and explore the full API catalog for related finance data.What does the /v2/interestrate response include?
A request to/v2/interestratereturns a JSON object withrate_name(the name of the rate),rate_pct(the rate value as a percentage), andlast_updated(the date the rate was last refreshed in MM-DD-YYYY format). See error codes for the response when a request is unsuccessful.How do I get historical interest rate data?
Use the/v2/interestratehistoricalendpoint with the samerateparameter plus an optional date range, eitherstart_dateandend_dateinYYYY-MM-DDformat orstart_timeandend_timeUNIX timestamps (in seconds); it returns up to 100 data points per call as adataarray of objects withtimestamp,date(YYYY-MM-DD) andrate_pct. Both endpoints are Premium only, so check our pricing page for access details.How fresh is the data and what can I build with it?
Rates are refreshed every 4 hours, making the API suitable for finance dashboards, mortgage and loan calculators, and macroeconomic monitoring tools. Pair it with the Mortgage Rate API, Inflation API, or Exchange Rate API for richer financial applications.
Explore API integration use cases for recommended APIs and workflow examples.