High Five! Some of our products use postal codes for geographical classifications. For example predicting the usage of heating energy based on past consumption depending on the outside temperature of your area. Postal codes are easier to remember than geo coordinates and: everybody has one.
In 1993 the Deutsche Bundespost introduced the 5-digit German postal codes. Today its successor the Deutsche Post AG is responsible for the assignment of postal codes. Changes are published quarterly in so called Mitteilungsblätter.
There are postal codes for ordinary delivery, bulk customers and post-office boxes. The geographical area of a postal code for ordinary delivery is defined by the streets and house numbers that share the same postal code. The geo coordinates of a postal code in terms of polygonal lines can only be deduced from that indirectly.
There is a free online service to obtain the addresses of a postal code and vice versa, but for the geo data the Deutsche Post AG wants to see cash.
The number of postal codes is quite stable. The last change of a delivery postal code was in September 2015, which was the discontinuation of 04579. Changes in the assignment of addresses to postal codes or changes of postal codes for bulk customers or post-office boxes however, are far more frequent.
The first digit of a postal code denotes a zone and the second a region within the zone. There are 8203 different postal codes for ordinary delivery, i.e. that are associated to a geographical area. However, four of them belong to Austrian territory: 87491 (Jungholz) and in the Kleinwalsertal: 87567 (Riezlern), 87568 (Hirschegg) and 87569 (Mittelberg).
There is a German postal code of a German city, that is ‚outside‘ of Germany, namely 78266 (Büsingen am Hochrhein) which is entirely surrounded by Swiss territory.
One might expect that the postal code areas coherent and disjoint areas. But far from the truth. There are postal code areas where one area lies entirely inside another area (e.g. 53879 in Euskirchen is enclosed by 53881). There are even cases where an area contains more than one other area, e.g. 56290 Beltheim contains two areas for 56288 Kastellaun. In this case 56288 consist of even three areas: two inside of 56290 and one next to it.