Indonesia Regions API Comparison 2026: emsifa, wilayah.id, BPS and API Indonesia
An honest comparison of the four most used Indonesian region APIs: province count, postal codes, coordinates, name search, cost, and when to use each one.

Search for an "Indonesia regions API" and four options keep coming up: emsifa/api-wilayah-indonesia, wilayah.id, the BPS Web API, and API Indonesia. All four can power a province-to-village address dropdown, but they work differently and carry different trade-offs. This comparison is based on calling each one directly on 24 October 2026.
At a glance
| emsifa (v2) | wilayah.id | BPS Web API | API Indonesia | |
|---|---|---|---|---|
| Type | Static JSON (GitHub Pages) | Static JSON | Official BPS API | REST API with an API key |
| Cost | Free | Free | Free, registration required | 3,000 credit signup bonus, then 2 credits (Rp2) per successful request |
| Provinces | 38 (under /v2/); the old /api/ endpoint still returns 34 |
38 | Follows BPS codes | 38 |
| Data reference | Kemendagri | Kepmendagri No 300.2.2-2138 of 2025 | BPS region codes | Kepmendagri 2025 (cahyadsn/wilayah transcription) |
| Village postal codes | Yes | No | No | Yes |
| Coordinates | All levels | No | No | Provinces (not yet villages) |
| Name search | No | No | Not built for address forms | Yes (/wilayah/search) |
| Other data on the same key | No | No | BPS statistics | 30 API products (holidays, postal codes, BMKG, Bank Indonesia rates and more) |
In short: for a free, static dropdown, emsifa v2 and wilayah.id are good choices. If you need name search, village postal codes from one endpoint, and other Indonesian public data behind a single key, API Indonesia is the more practical option.
1. emsifa/api-wilayah-indonesia
The most popular open-source source of Indonesian region data, served as static JSON files on GitHub Pages. No API key and no server-side rate limit.
Watch the version. The original endpoint at /api-wilayah-indonesia/api/provinces.json still returns 34 provinces, without the four newer provinces in Papua (Papua Selatan, Papua Tengah, Papua Pegunungan, Papua Barat Daya). The newer /api-wilayah-indonesia/v2/ endpoint returns 38 provinces and is much richer, with coordinates, population, area, and village postal codes. Many older tutorials still point at /api/.
Good for: frontend dropdowns, prototypes, zero-budget projects. Limits: no free-text search, only parent-ID navigation, and no uptime guarantee since it is community-run.
2. wilayah.id
A static API that follows Kepmendagri No 300.2.2-2138 of 2025, last updated 4 July 2025. Simple endpoints (provinces.json, regencies/{code}.json, districts/{code}.json, villages/{code}.json) with dotted codes such as 31.71.06.
Good for: the latest Kemendagri codes at no cost. Limits: codes and names only, with no postal codes, coordinates, or search.
3. BPS Web API
The official source from Statistics Indonesia (BPS), which requires registering for a key. A common pitfall: BPS region codes are not always the same as Kemendagri codes. If you store user addresses with Kemendagri codes (the ones used on ID cards and in government administration), do not mix in BPS codes without a mapping table.
Good for: statistics and research that use BPS codes. Limits: not designed for application address forms.
4. API Indonesia
A pay-per-use REST API with a 3,000 credit signup bonus (about 1,500 requests). Region data follows Kepmendagri 2025, with 91,599 rows from provinces down to villages, 38 provinces and 514 regencies/cities.
What it adds over the free options:
- Name search across levels. A user types "menteng" and you get the matching districts and villages.
- Postal codes on village records, plus a separate Postal Code API.
- One API key for 30 API products, including public holidays, prayer times, BMKG weather and earthquakes, Bank Indonesia exchange rates, and NIK/NPWP format validation.
- A uniform JSON envelope, a public status page at status.apiindonesia.id, an n8n community node, and an MCP server for AI agents.
One limit to know: coordinates are available at province level only for now. If you need a point per village, emsifa v2 is currently more complete for that.
Example: search a region by name
curl "https://use.apiindonesia.id/api/v1/wilayah/search?q=menteng" \
-H "x-api-key: YOUR_API_KEY"
{
"success": true,
"data": [
{ "id": "317106", "name": "Menteng", "alt_name": null, "level": "kecamatan" },
{ "id": "3171061001", "name": "Menteng", "alt_name": null, "level": "kelurahan" },
{ "id": "3174011003", "name": "Menteng Dalam", "alt_name": null, "level": "kelurahan" }
]
}
Example: villages with postal codes
curl "https://use.apiindonesia.id/api/v1/wilayah/kecamatan/317106/kelurahan" \
-H "x-api-key: YOUR_API_KEY"
{
"success": true,
"data": [
{ "id": "3171061001", "district_id": "317106", "name": "Menteng", "postal_code": "10310", "type": "kelurahan" },
{ "id": "3171061002", "district_id": "317106", "name": "Pegangsaan", "postal_code": "10320", "type": "kelurahan" },
{ "id": "3171061003", "district_id": "317106", "name": "Cikini", "postal_code": "10330", "type": "kelurahan" }
]
}
Full endpoint list: Regions API docs and the Regions API product page.
Which one should you pick?
- Prototype or simple dropdown, no budget: emsifa v2 (use
/v2/) or wilayah.id. - Production app that needs address search, postal codes, and other public data: API Indonesia.
- Statistical research: BPS Web API.
- Systems that must not depend on a third party at runtime: download a dataset (emsifa, cahyadsn/wilayah, or an export from an API), store it in your own database, and refresh it when a new Kepmendagri decree is issued.
Whatever you choose, store the region code, not just the name. Village names repeat across provinces (there are many "Menteng" and "Sukamaju"), while Kemendagri codes are unique.
FAQ
How many provinces does Indonesia have? 38, after Papua Selatan, Papua Tengah, Papua Pegunungan and Papua Barat Daya were created in 2022. An API that still returns 34 provinces is using old data.
Is the emsifa regions API still usable?
Yes. Use the /v2/ endpoints, which have 38 provinces plus postal codes and coordinates. The old /api/ endpoints still return 34 provinces.
What is the difference between Kemendagri and BPS region codes? Kemendagri codes are administrative (used on ID cards and official documents); BPS codes are statistical. They are often similar but not always identical, so do not mix them without a mapping.
Is API Indonesia free for region data? New accounts get a one-time 3,000 credit bonus, about 1,500 requests. After that each successful request costs 2 credits (Rp2) and failed requests are free. The Pro plan is Rp49,000/month for 50,000 credits.
Can I search villages by name?
With API Indonesia, yes, via GET /api/v1/wilayah/search?q=.... emsifa and wilayah.id only offer navigation by parent code.
Browse the data: regions by province and regency/city.
