GET /all

restcountries.com:rest-countries-api

Summary: Get all countries
Operation ID: getAllCountries
Auth: none

Returns the complete list of all countries in the world with full country data. This is the main bulk endpoint - you get everything from country codes and capitals to currencies, languages, population, borders, timezones, and flag URLs. The response is a JSON array with ~250 country objects. Use this when you need the entire dataset, or combine with the fields parameter to limit which data fields come back.

Original spec description

Returns data for all countries. The 'fields' parameter is required to limit the response size (max 10 fields).

Usage Tips

- Response is large (~600KB+ uncompressed with all fields); use `fields` parameter to limit data - Consider caching this response rather than calling it repeatedly - Returns array of country objects - even single-country lookups by code use this endpoint

Parameters (1)

fields (string, query, required)

Comma-separated list of fields to include (required, max 10 fields)

Examples (6)

TitleTypeURLAction
Get all countries openapi-spec https://restcountries.com/v3.1/all?fields=name,capital,flags
Get all countries openapi-spec https://restcountries.com/v3.1/all?fields=name,capital,population,region
Get all countries openapi-spec https://restcountries.com/v3/all?fields=name,capital,population,region
Get all countries openapi-spec https://restcountries.com/v3.1/all?fields=name,capital,population
Get all countries openapi-spec https://restcountries.com/v3.1/all?fields=name,capital,currencies
Get all countries probe-gate https://restcountries.com/v3.1/all?fields=name%2Ccapital%2Ccurrencies

Probe History

Latency

Status Codes

TimeStatusLatencySize
2026-03-23 10:34:28.194500 200 413ms
2026-03-23 10:33:05.450113 200 405ms
2026-03-23 10:29:14.359549 200 526ms
2026-03-23 10:12:04.895657 200 426ms
2026-03-23 09:49:17.002212 200 490ms
2026-03-23 09:45:20.248026 200 402ms
2026-03-20T02:21:04.505991 200 620ms

Response Changes

WhenOldNew
2026-03-23 09:45:20.248026 e100460844d9 d3a427cef42a
2026-03-23 09:49:17.002212 d3a427cef42a 88e760ece608
2026-03-23 10:12:04.895657 88e760ece608 48779cff36db
2026-03-23 10:33:05.450113 48779cff36db a2abc5d70893
2026-03-23 10:34:28.194500 a2abc5d70893 0373d4cf7515