Skip to content
freetier.wiki

Type at least 2 letters.

Enter to open · Esc to close

Country-State-City Microservice API

Country-State-City Microservice API allows 100 requests a day for free with no card and no overage, and higher usage means contacting the provider, while enforcement is not confirmed.

The Country-State-City Microservice API is a free REST API that returns countries, states, cities, and postal code matches as JSON. It suits developers who need location data for forms and small projects.

By RebuscandoAPIs & dataChecked ✓ 15 Nov 2026

Is it a fit?

Good fit

Use when you need country, state, and city data for forms or a small location feature, and 100 requests a day is enough for development or a small project.

  • form dropdowns
  • prototyping
  • student projects
  • small apps

Not a fit

Avoid if you need more than 100 requests per day without contacting the provider, or a service with a guaranteed uptime and official support.

  • traffic above 100 requests per day
  • uptime guarantees
  • official support needs

You call four public endpoints with plain GET requests from any language. The docs show Python examples that use the requests library. It suits developers who need location data for dropdowns, forms, and small apps.

What the free plan gives you

The free tier allows up to 100 requests per day. The site says this is enough for development and small projects. There is no price on the free tier page, and the docs examples call the public endpoints with no API key.

The four endpoints list countries, list the states of a country, list the cities of a state, and find the state and cities for a postal code within a country. The site also links to a free geocoding API and a Python examples page that uses the requests library.

When you hit a limit

The free tier page does not say what happens after you pass 100 requests in a day. It does not describe overage charges or an error code. It asks you to email the provider for larger projects and for information about higher usage plans.

Because the page lists no paid plan and no billing step, a charge looks unlikely. The page does not establish whether requests fail or are refused above the daily limit. Cache the country and state lists in your app so each page view does not use a request.

Gotchas

  • The free tier page only gives the daily request count. It does not set out uptime promises or support terms.
  • Higher usage plans are not listed. You must contact the provider to ask about them.
  • The endpoints take database IDs, such as an id for a country, so you call countries first and then use the returned IDs for states and cities.

Alternatives in this atlas

  • Zipcodebase: when you mainly need postal code lookups and distance search.
  • Zipcodestack: when you need postal code lookups with a monthly request allowance.
  • Geolocated.io: when you need to find a user's location from their IP address instead.

Questions people ask

Is the Country-State-City API free?

Yes. The free tier includes up to 100 requests per day. The site calls this enough for development and small projects.

What happens when I go over the Country-State-City API limit?

The free tier page does not say. It tells you to contact the provider for larger projects and for higher usage plans.

Do I need an API key for the Country-State-City API?

The docs examples call the public endpoints with a plain GET request and no key. The pages do not describe a sign-up step.

How to get started

  1. Open the Country-State-City site and read the free tier page: the free tier allows up to 100 requests per day.
  2. No account or key step is shown in the docs; the examples call the public endpoints directly.
  3. Send a GET request to https://api.country-state-city.rebuscando.info/public/getCountries to list countries.
  4. Call getStates with the idcountry parameter, then getCities with the idstate parameter.
  5. Use getStateAndCitiesByPostalCodeAndCountryId with idcountry and postalcode to find the state and cities for a postal code.
  6. For Python, install the requests library with pip and use the examples on the Python usage page.

Other free apis & data options

Same category, safest first.

Open-Meteo · APIs & data
10,000 API calls per day · 600 API calls per minute and 5,000 per hour · 300,000 API calls per month listed; monthly limits currently not enforced
Billing risk: None
No card
Esri · APIs & data
2M basemap tiles or 1K basemap sessions per month · 20K geocodes (not stored) per month · 20K routes and 5K service areas per month
Billing risk: None
No card
ipwho.org · APIs & data
2,000 lookups/day on the free plan, hard limit · All fields included on every plan, no feature gating · No credit card required
Billing risk: None
No card
ip-api · APIs & data
45 requests per minute per IP · HTTP only (no HTTPS) · No API key or registration required
Billing risk: None
No card