← Docs

Country API

A country by code or name. Currency, timezones, plugs, tax, states.

Look up a country by ISO2, ISO3, or its name. us, usa, and united states are the same record, and accents are optional (cote divoire works). Response country is always ISO2. Capital, currency, languages, borders, timezones, plug types with voltage, emergency numbers, the national sales tax, and the rest.

Lookup

GET
api.parseapi.com/country/{code}
By code or name. Currency, timezones, plugs, tax, emergency numbers
curl "https://api.parseapi.com/country/us" \
  -H "X-API-Key: YOUR_API_KEY"
{
  "country": "US",
  "iso3": "USA",
  "numeric": 840,
  "name": "United States",
  "full_name": "United States of America",
  "local_name": "United States",
  "demonym": "American",
  "capital": "Washington, D.C.",
  "capital_lat": 38.89,
  "capital_lon": -77.05,
  "continent": "NA",
  "region": "Americas",
  "subregion": "Northern America",
  "population": 340110988,
  "area": 9629091,
  "currency": "USD",
  "currency_name": "United States Dollar",
  "currency_symbol": "$",
  "tld": ".us",
  "calling_code": "+1",
  "emoji": "🇺🇸",
  "languages": [
    "en"
  ],
  "borders": [
    "CA",
    "MX"
  ],
  "blocs": [
    "G7",
    "NATO",
    "OECD"
  ],
  "timezones": [
    "America/Adak",
    "America/Anchorage",
    "America/Boise",
    "America/Chicago",
    // ... 25 more
  ],
  "week_start": "sunday",
  "units": "imperial",
  "driving_side": "right",
  "plugs": [
    "A",
    "B"
  ],
  "voltage": 120,
  "frequency": 60,
  "emergency": {
    "police": "911",
    "ambulance": "911",
    "fire": "911"
  },
  "postal_format": "#####",
  "postal_regex": "^(?:(\\d{5})(?:[ \\-](\\d{4}))?)$",
  "tax": null,
  "tax_rate": null,
  "tax_id_format": null,
  "tax_id_regex": null,
  "ioc": "USA",
  "fifa": "USA",
  "plate": "USA"
}

Response fields

country
ISO2 country code
iso3
Three-letter country code
numeric
UN numeric code
name
Common name
full_name
Official long name
local_name
Local-language name
demonym
Demonym
capital
Capital city
capital_lat
Capital latitude (null when there is no capital)
capital_lon
Capital longitude (null when there is no capital)
continent
Continent code (NA, EU, AF, AS, OC, SA, AN)
region
UN region
subregion
UN subregion
population
Population estimate
area
Total area in km²
currency
ISO currency code
currency_name
Currency name
currency_symbol
Currency symbol
tld
Top-level domain
calling_code
International calling code with plus (+1, +44)
emoji
Flag emoji
languages
ISO 639 language codes. Expand each at /language/{code}
borders
Neighboring country ISO2 codes
blocs
Bloc memberships (EU, EEA, SCHENGEN, EUROZONE, SEPA, NATO, and more). Expand each at /bloc/{code}
timezones
IANA timezone ids used in the country. The US lists 29
week_start
First day of the week (monday, sunday, saturday)
units
Measurement system (metric or imperial)
driving_side
left or right
plugs
Power plug types, IEC letters (A through O)
voltage
Residential mains voltage. Null when no single standard exists
frequency
Mains frequency in Hz. Null when the grid is split (Japan runs both 50 and 60)
emergency
Emergency numbers: police, ambulance, fire. Null when not confirmed
postal_format
Postal code mask, # is a digit and A is a letter. Null when the country has no postal codes
postal_regex
Anchored regex matching valid postal codes
tax
National sales tax name (VAT, GST). Null when there is none, like the US
tax_rate
Standard rate as a percent (19, 8.1)
tax_id_format
Tax id example format, 9 is a digit (DE999999999)
tax_id_regex
Anchored regex matching valid tax ids
ioc
Olympic committee code (GER, NED, SUI)
fifa
FIFA code. Null for GB, the home nations are the members
plate
International vehicle plate code (D, UK, CH)

States in a country

Every state or region in that country. Built for address forms and shipping rules.

GET
api.parseapi.com/country/{code}/states
States and regions in a country
curl "https://api.parseapi.com/country/us/states" \
  -H "X-API-Key: YOUR_API_KEY"
{
  "country": "US",
  "states": [
    {
      "state": "AL",
      "name": "Alabama",
      "type": "state"
    },
    {
      "state": "AK",
      "name": "Alaska",
      "type": "state"
    },
    {
      "state": "NC",
      "name": "North Carolina",
      "type": "state"
    },
    // ... 57 more
  ]
}

Response fields

country
ISO2 country code
states
Every state or province in the country
states[].state
State or province code
states[].name
State or province name
states[].type
State, province, etc.

Questions? Email