The German town law (German: Deutsches Stadtrecht) or German municipal concerns (Deutsches Städtewesen) was a set of early town privileges based on the Magdeburg rights developed by Otto I. The Magdeburg Law became the inspiration for regional town charters not only in Germany, but also in Central and Eastern Europe who modified it during the Middle Ages. The German town law (based on Magdeburg rights) was used in the founding of many German cities, towns, and villages beginning in the 13th century.
As Germans began establishing towns throughout northern Europe as early as the 10th century, they often received town privileges granting them autonomy from local secular or religious rulers. Such privileges often included the right to self-governance, economic autonomy, criminal courts, and militia. Town laws were more or less entirely copied from neighboring towns, such as the Westphalian towns of Soest, Dortmund, Minden, and Münster. As Germans began settling eastward, the colonists modelled their town laws on the pre-existing 12th century laws of Cologne in the west, Lübeck in the north (Lübeck law), Magdeburg in the east (Magdeburg rights), and either Nuremberg or Vienna in the south.
The granting of German city rights modelled after an established town to a new town regarded the original model as a Rechtsvorort, or roughly a legal sponsor of the newly chartered town. For instance, Magdeburg became the sponsor of towns using Magdeburg Rights, and its lay judges could rule in ambiguous legal cases in towns using such rights. Certain city rights became known under different names, although they originally came from the same source; the name of some city variants designates the Rechtsvorort they became famous from, not necessarily that that specific style of rights originated from the Rechtsvorort. As territorial borders changed through the passage of time, changes to German city rights were inevitable.
During the course of the 15th, 16th, and 17th centuries, the town laws of many places were modified with aspects of Roman law by legal experts. Ultimately, the older towns' laws, along with local autonomy and jurisdiction, gave way to landed territorial rulers. With the Reichsdeputationshauptschluss of 1803, almost all of the 51 reichsfrei cities of the Holy Roman Empire were mediatised by the territorial princes; the remaining imperial free cities of Frankfurt, Bremen, Hamburg, and Lübeck became sovereign city-states. The only remnants of medieval town rights (statutes) included in the Bürgerliches Gesetzbuch of 1 January 1900 were single articles concerning family and inheritance laws. The cities of Hamburg, Bremen, and Berlin are currently administered under Landesrechte, or laws of the federal states of Germany.
Many towns granted German city rights had already existed for some time, but the granting of town law codified the legal status of the settlement. Many European localities date their foundation to their reception of a town charter, even though they had existed as a settlement beforehand.
German town law was frequently applied during the Ostsiedlung of Central and Eastern Europe by German colonists beginning in the early 13th century. Because many areas were considered underpopulated or underdeveloped, local rulers offered urban privileges to peasants from German lands to induce them to immigrate eastward. Some towns which received a German town law charter were based on pre-existing settlements, while others were constructed anew by colonists. Many towns were formed in conjunction with the settlement of nearby rural communities, but the towns' urban rights were jealously guarded. Initially German town law was applied only to ethnic Germans, but gradually in most localities all town-dwellers were regarded as citizens, regardless of ethnic origin.
Lübeck law spread rapidly among the maritime settlements along the southern shore of the Baltic Sea and was used in northern Mecklenburg, Western Pomerania, and parts of Pomerelia and Warmia. It formed the basis of Riga law in Riga, used for some towns in the lands of the Livonian Order in Livonia, Estonia, and Courland.
Magdeburg law was popular around the March of Meißen and Upper Saxony and was the source of several variants, including Neumarkt-Magdeburg law (?roda ?l?ska), used extensively in Upper Silesia, and Kulm law, used in the territory of the Teutonic Knights in Prussia and along the lower Vistula in Eastern Pomerania. Other variants included Brandenburg, Litomice, and Olomouc law.
Litomice law and codes based on that of Nuremberg, such as Old Prague and Cheb law, were introduced into Bohemia during the reign of King Wenceslaus I, while German colonists introduced Brünn (Brno) and Olmütz (Olomouc) law in Moravia. South German law, broadly referring to the codes of Nuremberg and Vienna, was used in Bavaria, Austria, and Slovenia, and was introduced into the Kingdom of Hungary during the rule of King Béla IV. Jihlava law was a variant used frequently by mining communities in Bohemia, Moravia, the mountains of Upper Hungary, and Transylvania. Other town laws were only suitable for or were modified to fit local conditions, such as G?ubczyce, Görlitz, Goslar, Lüneburg, Lwówek ?l?ski, Nysa, Spi?, and Székesfehérvár laws.
Resulting from the reign of King Casimir III of Poland, numerous towns were chartered with Neumarkt town law throughout the Kingdom of Poland in the 14th century, especially in Masovia, Galicia, and Volhynia. Many Transylvanian Saxon settlements in Transylvania, especially in the regions of Altland, Burzenland, and Nösnerland, received South German town law in the 14th century.
In the 15th century, many towns in the Grand Duchy of Lithuania were chartered with the Neumarkt town law used in much of Poland, although this was done through the duplication of Polish administrative methods instead of German colonization. In the 16th century Muscovy granted or reaffirmed Magdeburg rights to various towns along the Dnieper acquired from the Polish-Lithuanian Commonwealth. After the Partitions of Poland, Magdeburg law continued to be used in western Imperial Russia until the 1830s.