Datatypes › United Kingdom › Geographic identifiers

UK postcode district (outward code)

ID gb_postcode_district

DatatypeNot PIIcategoricalDraft

This record is a draft: it has not been reviewed yet and may be incomplete or wrong. Do not rely on it for compliance decisions. Help improve it (see CONTRIBUTING.md).

Outward code of a UK postcode, the part before the space: the postcode area letters and the district number (LS13, NW1, WC1H). Data published at postcode district level gives it instead of full postcodes.

Parent datatype
Postal code/index postindex
Categories
Geographic identifiers
Countries
United Kingdom
Languages
English
Quality
85/100 · missing: mapping (Wikidata, Schema.org, ...), translation
Metacrafter rules
1 rule (1 by field name, 0 by value)
Supported by tools
metacrafter

Regular expression

^[A-Z]{1,2}\d[A-Z\d]?$

Python re syntax.

Test a value

Examples

ValueDescription
LS13 Leeds
NW1 London NW1
WC1H London WC1H
N6 London N6
LS13 5 invalid A postcode sector
LS13 5LP invalid A full postcode

Sources

Use this record