---
id: "de_kreisschluessel"
kind: "datatype"
status: "stable"
is_pii: false
categories: ["geo"]
country: ["DE"]
langs: ["common"]
quality: 90
url: "http://registry.apicrafter.io/datatype/de_kreisschluessel"
---

# German district key (Kreisschlüssel) (`de_kreisschluessel`)

Five-digit official code of a German district (Landkreis) or independent city: two digits for the state, one for the government region and two for the district. It is the first five digits of the municipality key (AGS).

- Personal data (PII): no
- Categories: Geographic identifiers (geo)
- Countries: Germany (DE)
- Languages: Common to most languages (common)
- Classification: identifier

## Detection

Regular expression (Python `re`):

```
^(?:0[1-9]|1[0-6])\d{3}$
```

## Examples

- `03459` — Osnabrück District
- `07132` — Altenkirchen district
- `3459` (invalid example) — Leading zero dropped
- `18132` (invalid example) — There is no state 18

## Mappings

- wikidata: `P440`

## Translations

- de: Kreisschlüssel
- ru: Код района Германии (Kreisschlüssel): Пятизначный код района или города районного подчинения - первые пять цифр кода общины (AGS).

## Sources

- wikipedia: <https://de.wikipedia.org/wiki/Kreisschl%C3%BCssel>
- wikidata: <https://www.wikidata.org/wiki/Property:P440>

## Quality

Score 90/100. Missing: detector coverage.

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