Central Banks & Monetary

Consumer Price Index and core measures

Total CPI year-over-year (STATIC_ATABLE_V41690973) plus the three core-inflation measures the Bank of Canada monitors:

  • CPI_TRIM - CPI-trim, trims 20% of outlier prices each month
  • CPI_MEDIAN - CPI-median, the 50th-percentile year-over-year change across the basket
  • CPI_COMMON - CPI-common, factor-analytic estimate of common price movements

All monthly, published by Statistics Canada and mirrored via the Valet API. Bank of Canada targets 2% total CPI with a 1% to 3% band.

get/api/v1/boc/cpi

Query parameters

recent_yearsinteger

Number of years of CPI history.

Number of years of CPI history.

Response

Monthly total CPI year-over-year and three core inflation measures.

Example response

{
  "meta": {
    "endpoint": "/api/v1/fred/us/cpi",
    "data_time": "2026-04-16T14:30:00Z",
    "response_time": "2026-04-16T14:30:12Z",
    "provider": "Sugra API v1.0.1",
    "source": "sugra_crypto",
    "attribution": "Short interest and Reg SHO daily short volume data is owned by and sourced from FINRA (Financial Industry Regulatory Authority).",
    "fallback_chain": [
      "sugra_crypto",
      "sugra_finance"
    ]
  }
}

Changes

Changed in 2 of the 21 revisions of this API.612

    • the response property data/count became optional for the status 200

      response-property-became-optional

    • the response property data/observations became optional for the status 200

      response-property-became-optional

    • the response property data/seriesDetail became optional for the status 200

      response-property-became-optional

    • response property data/count list-of-types was widened by adding types null and number to media type application/json of response 200

      response-property-list-of-types-widened

    • response property data/observations list-of-types was widened by adding types null to media type application/json of response 200

      response-property-list-of-types-widened

    • response property data/seriesDetail list-of-types was widened by adding types null to media type application/json of response 200

      response-property-list-of-types-widened

    This revision also has 15 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog

    • added the optional property code to the response with the 401 status

      response-optional-property-added

    • added the optional property code to the response with the 429 status

      response-optional-property-added

    • added the optional property code to the response with the 503 status

      response-optional-property-added

    • added the optional property hint to the response with the 401 status

      response-optional-property-added

    • added the optional property hint to the response with the 429 status

      response-optional-property-added

    • added the optional property hint to the response with the 503 status

      response-optional-property-added

    • added the optional property plan to the response with the 401 status

      response-optional-property-added

    • added the optional property plan to the response with the 429 status

      response-optional-property-added

    • added the optional property plan to the response with the 503 status

      response-optional-property-added

    • added the optional property reason to the response with the 401 status

      response-optional-property-added

    • added the optional property reason to the response with the 429 status

      response-optional-property-added

    • added the optional property reason to the response with the 503 status

      response-optional-property-added