

World countries, states, regions, provinces, cities & towns in JSON, SQL, XML, YAML, & CSV format.
CountryStateCity API is a free Geocoding API that requires apiKey authentication, is served over HTTPS and supports CORS, so it can be called from the browser.
250 countries, 5,300+ states and 150,000+ cities via REST API, free database downloads and offline packages. Free API tier available.
Details from countrystatecity.in.

Unified API suite · now live
Geocode an address, validate an email, track a flight or pull stock data with one account, one dashboard and one API key.
Brazil RESTful API to find information about streets, zip codes, neighborhoods, cities and states
The CountryStateCity API is provided by CSC Database (countrystatecity.in). 250 countries, 5,300+ states and 150,000+ cities via REST API, free database downloads and offline packages. Free API tier available.
Yes. The CountryStateCity API is listed in the Geocoding category of the public-apis directory, which only includes APIs that are free or have a free tier. Check its documentation for rate limits and paid plans.
Yes. The CountryStateCity API uses apiKey authentication, so you need to register for credentials before making requests.
Yes. The CountryStateCity API supports CORS, so front-end JavaScript can call it directly.
Yes. The CountryStateCity API is served over HTTPS, so it's safe to use in production.