There was originally a Roman castellum (Castellum Laurum) in Woerden, as part of the limes of the Roman Empire and thus part of the defense lines of the northern border of the Roman Empire. The first castellum was built in the 40s AD, and was destroyed in 69 AD during the Batavian rebellion. In 70 AD the castellum was rebuilt, and the Romans remained until 402 AD, with an interruption lasting from about 275-300 AD. The Castellum was located at the present site of the medieval Petruschurch and surrounding church yard. During construction work on a new underground parking facility in the city center of Woerden, the remains of numerous old Roman buildings and a Roman cargo ship were found.
The current castle was built in around 1160 by bishop Godfrey van Rhenen. Due to its strategic location on the border between the County of Holland and the Bishopric of Utrecht, various wars have been fought in and around Woerden. In 1410 John III, Duke of Bavaria-Straubing reconstructed the castle.
Until the 19th century the castle was used as a prison. There's even a pit prison in the northwest tower, which was used for unruly prisoners. In the 20th century the castle was part of military barracks and used for storage of all kinds of goods but poorly maintained. This caused severe decay. Today it is restored as a restaurant.References:
The Château Comtal (Count’s Castle) is a medieval castle within the Cité of Carcassonne, the largest city in Europe with its city walls still intact. The Château Comtal has a strong claim to be called a 'Cathar Castle'. When the Catholic Crusader army arrived in 1209 they first attacked Raymond-Roger Trencavel's castrum at Bèziers and then moved on to his main stronghold at Carcassonne.
The castle with rectangular shape is separated from the city by a deep ditch and defended by two barbicans. There are six towers curtain walls.
The castle was restored in 1853 by the architect Eugène Viollet-le-Duc. It was added to the UNESCO list of World Heritage Sites in 1997.