Urban castle

An urban castle (Stadtburg) is a castle that is located within a medieval town or city and/or is integrated into its fortifications.

In most cases, the town or city grew up around or alongside the castle (for example in Halle, Brunswick and Prague), or the castle was built in order to reinforce the defences within or as part of the line of fortification ringing the settlement as, for example, at Erfurt.

Definitions
Creighton draws a distinction between the 'urban castle', where the castle is built in or onto an existing town, and the 'castle borough', "where a primary castle attracts a secondary borough or the two are planned together," although he acknowledges that the division between the two is not always clear-cut.

Instrument of sovereign power
The urban castle was also be used as an instrument of power, for example by William the Conqueror in Norman England, or by territorial lords in the Holy Roman Empire when towns in the late Middle Ages were increasingly striving for their independence. In such cases the urban castle was integrated into a strategically favourable point in the city wall so that the lord could enter the castle from the fields outside unhindered by the citizens and, through another gateway in the castle walls facing the city, could leave the castle and enter the city.

Austria

 * Krems in Lower Austria, has the Gozzoburg, a high mediaeval urban castle.

Germany
There are examples of urban castles in:
 * Andernach in Rhineland-Palatinate where the Electoral Cologne Stadtburg (designed as a water castle) as an instrument of power
 * Erfurt with its Petersberg Citadel, which is integrated into the defensive system of the old fortified city
 * Esslingen am Neckar: the original outposts on the Schönenberg were gradually incorporated into the town fortifications through the construction of branching walls (Schenkelmauern). Due to the geological situation there, the cost was very high.
 * Feuchtwangen in Bavaria still has, in the remains of its town walls, a picturesque link to the site of Little Ottingen Castle (Öttingischen Schlösschen), a former water castle, which juts out from the otherwise circular town wall. Later a small hunting lodge was built on the site
 * Friedberg in Hesse has an imperial castle
 * Horn-Bad Meinberg in North Rhine-Westphalia has Horn Castle, a castle built into the town's defences
 * Nuremberg: the double castle is incorporated into the city wall
 * Schlitz in Hesse, one of the best-known examples of urban castles in Germany with four castles.
 * Warburg has Wartberch Castle.
 * Weißenstein with the old castle of Schloss Weißenstein

United Kingdom
The Tower of London has been called "the most complete of urban castles", and an "archetypally oppressive castle." Other examples include:
 * Baile Hill, York
 * Banbury Castle
 * Baynard's Castle
 * Bristol Castle
 * Castle Acre
 * Caernarvon Castle
 * Conway Castle
 * Flint Castle
 * Mountfichet Castle
 * Oxford Castle
 * Rhuddlan Castle