---
id: "jp_lg_code"
kind: "datatype"
status: "draft"
is_pii: false
categories: ["geo", "government"]
country: ["JP"]
langs: ["common"]
quality: 80
url: "http://registry.apicrafter.io/datatype/jp_lg_code"
---

# Japanese local government code (dantai code) (`jp_lg_code`)

> **Draft.** Draft records have not been reviewed yet and may be incomplete or wrong; do not treat them as authoritative for legal or compliance decisions.

Six-digit code of a Japanese prefecture or municipality defined by the Ministry of Internal Affairs and Communications (JIS X 0402 plus a check digit). The first two digits are the prefecture.

- Personal data (PII): no
- Categories: Geographic identifiers (geo), Government related (government)
- Countries: Japan (JP)
- Languages: Common to most languages (common)
- Classification: identifier

## Detection

Regular expression (Python `re`):

```
^\d{6}$
```

## Examples

- `261009` — Kyoto
- `011002` — Sapporo

## Mappings

- wikidata: `P429`

## Sources

- wikipedia: <https://ja.wikipedia.org/wiki/%E5%85%A8%E5%9B%BD%E5%9C%B0%E6%96%B9%E5%85%AC%E5%85%B1%E5%9B%A3%E4%BD%93%E3%82%B3%E3%83%BC%E3%83%89>
- wikidata: <https://www.wikidata.org/wiki/Property:P429>

## Quality

Score 80/100. Missing: negative example, translation, detector coverage.

JSON: <http://registry.apicrafter.io/api/v1/datatypes/jp_lg_code.json> · Edit: <https://github.com/apicrafter/metacrafter-registry/edit/main/data/datatypes/JP/geo/jp_lg_code.yaml>
