Documentation Python quickstart Blog Free tools Enterprise solutions hello@quanticdata.ioLog in
All collectors

World Bank API

Research & science · v1.1.0 · world_bank

$0.0002 / datapoint

$0.20 / 1K · pay per delivered datapoint

A World Bank API call takes one indicator code and a set of countries and returns a clean panel: one row per country-year with the numeric value, the ISO3 code and the indicator's label. NY.GDP.MKTP.CD makes it a GDP API, SP.POP.TOTL a population series, FP.CPI.TOTL.ZG an inflation feed — the Bank's roughly 16,000 indicator codes all answer in the same shape, keyless.

$0.0002 per delivered datapoint · $2 free every month · Failed runs never billed

What it does

What a World Bank API does

The World Bank indicators API is open and official, but it answers in paged JSON with a metadata envelope in front of the data. Here the panel arrives already long-format — country, year, value — which is the layout a pivot, a regression or a database table accepts without reshaping, joined on country_code plus year.

Years the Bank holds no figure for are skipped by default, so the series you store is dense rather than padded with nulls; set include_empty when the gaps need to stay visible. Up to 30 countries ride in one call, ISO2 or ISO3, and aggregate codes like WLD pass through the same way — a country data API that also covers the world total.

Inputs

The whole request. Anything you leave out falls back to the default shown in the catalog.

InputTypeRequiredWhat it does
indicatorstringyesWorld Bank indicator code.
countriesarrayyesISO2/ISO3 country codes.
year_fromintegernoFirst year (default: all).
year_tointegernoLast year (default: latest).
include_emptybooleannoKeep rows whose value is null.
max_resultsintegernoHow many datapoints to deliver at most (1–200). You pay only for delivered datapoints.

Outputs — 10 fields, one row per datapoint

What one datapoint looks like

Every delivered datapoint carries these fields. Nullable means the source did not publish it — the field stays empty instead of being guessed.

FieldTypeWhat it holds
rankinteger1-based position.
countrystring · nullableCountry name.
country_codestring · nullableISO3 code.
yearstring · nullableYear.
valuenumber · nullableIndicator value.
indicatorstringIndicator code.
indicator_namestring · nullableIndicator label.
country_iso2string · nullableISO 3166-1 alpha-2 country code.
unitstring · nullableUnit, when the Bank states one.
obs_statusstring · nullableObservation status flag, when present.

Integration

One POST, typed rows

Base URL https://api.quanticdata.io/v1, Bearer auth, the same key as every other Data API. Endpoint: POST /v1/scraper/collectors/world_bank/run.

curl -X POST https://api.quanticdata.io/v1/scraper/collectors/world_bank/run \
  -H "Authorization: Bearer $QD_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'

Example response

POST /v1/scraper/collectors/world_bank/run
$ curl $QD/world_bank/run \
    -H "Authorization: Bearer $QD_API_KEY" \
    -d '{}'
{ "status": "done", "count": 10,
  "results": [
    {
      "country": "…",
      "country_code": "…",
      "year": "…",
      "value": … } ],
  "cost": 0.002 }
# 10 datapoints × $0.0002 · nothing delivered, nothing charged

Try it

World Bank indicators, running now

Change the input and run it against the live collector — nothing to install, no sign-up.

Run it from your own code, on your own inputs

Same collector, same rows — $2 of free API credit every month, no card.

Get my free API key
World Bank API: from indicator and countries, QuanticData reads the development indicators and returns one row per datapoint with indicator_name, country_code and year, at $0.0002 per delivered datapoint.
You send indicator and countries; the run reads the source and comes back as datapoints with rank, country and country_code — 10 fields on every row — and you are billed $0.0002 for each datapoint actually delivered, nothing for a run that delivers none.
$0.0002 / datapoint10,000 datapoints on the free $2 every month
Semantic inputindicator, countries, year_from — no URL lists
Up to 200datapoints per run, pagination handled for you
No browserread over HTTP/TLS — cheaper and faster than rendering

Pricing

World Bank API pricing

$0.0002 per delivered datapoint. A run that delivers nothing costs nothing: blocked pages, challenges and retries are on us, and the $2 monthly allowance covers about 10,000 datapoints before you spend anything.

$0.0002per delivered datapoint$0.2 per 1,000 delivered datapoints
10,000 datapointson the free allowance$2 every month, no card
Zero rowszero chargeblocks, captchas and retries are on us
−30%on volume tiersthe catalog returns your key's price

Same wallet, same key and same $2 monthly allowance as every other Data API. Prices are launch pricing read live from the billing config — GET /v1/scraper/collectors returns the price your key actually pays.

What people build with the World Bank API

Three shapes of work this endpoint was designed around.

Macro feature panels

Pull GDP, inflation or population per country-year and join them onto your observations as model features keyed by country code and year.

Country enrichment joins

A market-sizing or lead table with a country column picks up population and income columns from one indicator call each.

Long-run trend series

year_from reaches back toward 1960, so a single request returns decades of one indicator for charting or back-testing.

World Bank API versus rolling your own

The differences that actually cost time when you build this in-house.

DIY scraperThis collector
Panel shapePaged JSON behind a metadata envelopeLong-format rows: country, year, value
Missing yearsNulls scattered through the seriesSkipped by default, kept only on request
Batching countriesA request loop over country codesUp to 30 countries in a single call

What people search for

Live autocomplete demand around World Bank indicators, pulled with our own Keyword ideas collector.

World Bank API: the POST to the world_bank collector, 200 datapoints delivered and the bill, 200 × $0.0002 = $0.04 in usage.cost_usd; zero datapoints would cost $0.
The same call you would paste into a terminal: a Bearer key, indicator, countries and year_from in the body, and back the envelope every QuanticData endpoint returns — type, message, payload — where count is how many datapoints arrived and usage.cost_usd is $0.04, which is 200 × $0.0002. A run that delivers nothing costs nothing. The key is good for 60 req/min on the free tier.

Sources and standards

The platform documentation and standards this collector is built against — check any claim on this page against the primary source:

FAQ

Questions we get about the World Bank API.

Something else? Ask us

Which indicator codes does the World Bank API accept?

Any code from the Bank's catalog of roughly 16,000 — NY.GDP.MKTP.CD for GDP in current US dollars, SP.POP.TOTL for population, FP.CPI.TOTL.ZG for CPI inflation — one indicator per call, across the countries you list.

Why are some years missing from the series?

Because the Bank publishes no figure for them. Null-value years are dropped so the panel stays dense; pass include_empty as true and they come back as rows with a null value instead.

Can I query world or regional aggregates?

Yes — aggregate codes such as WLD for the world total travel through the countries list exactly like ISO codes, so a global series and a country comparison come from the same call shape.

Is there a free World Bank API?

Every account gets $2 of credit every month with no card, which is about 10,000 delivered datapoints on this endpoint at $0.0002 each. It renews monthly, and a run that delivers nothing is never billed — so a failed or blocked attempt does not eat the allowance.

How much does one run cost?

Multiply the rows you actually receive by $0.0002. A run capped at 200 datapoints — the maximum for this collector — costs $0.04 if every row comes back, and less when the source has fewer. Volume tiers take up to 30% off, and GET /v1/scraper/collectors returns the price your key actually pays.

Run the World Bank API now

$2 of free credit every month, no card. Your key returns its own prices from GET /v1/scraper/collectors.

Run in dashboard
Illustration: three coloured zones of the page that is read (Development indicators) turn into clean JSON with the fields indicator_name, country_code and year; 10 fields on every row.