The oldest settlement originally called Koziegłówki is known for the years 1326-1327. Its heir in 1366 was Prandota, who is considered to be father of Krystyn of Koziegłowy, the first known owner of the castle. It was probably built in the first half of the 14th century and was a defensive residence of heirs and an administrative center of vast estates. It was in possession of Koziegłowski family until 1519. At that time, the castle was purchased by the bishop of Kraków, Jan Konarski, and from that time property belonged to the Cracow bishopric. In 1598 the castle was completely ruined, and the remains of the building were finally demolished in the 19th century in order to paved the local road.
The castle was erected among marshy meadows of a swampy valley, east of the town. A small hill on which it was located from the north and east was surrounded by Sarni Stok stream. It was built of limestones, and its defensive walls were arranged on a rectangular plan with dimensions of 50×25 meters. Walls had a thickness of up to 1.4 meters. In the western part of the inner courtyard, a residential building was erected on a rectangular plan with a width of 8 meters, length could not be determined. On the eastern side of the building stretched a cobbled courtyard. The entrance to the castle was from the east and led through the gatehouse tower, attached from the outside to the perimeter wall. It was erected on a square plan with a side of 9 meters and was reinforced with buttresses. The tower walls were up to 2.4 meters thick. A 125-meter long dike was leading to the gate.
The whole castle was surrounded by two rings of earth ramparts, separated by a moat. Probably on the eastern side there was an oval outer ward, surrounded by an additional moat and earth rampart. The internal rampart from the moat side was lined with fascine. Documents show that there was in castle a bakery, a chapel and a and a room at the tower.
The castle has not survived to modern times. Admission to the area, where the remains of foundations and the outline of the moats are visible, is free.
Kołodziejski S., Średniowieczne rezydencje obronne możnowładztwa na terenie województwa krakowskiego, Warszawa 1994.
Lasek P., Obronne siedziby rycerskie i możnowładcze w czasach Kazimierza Wielkiego [w:] Wielkie murowanie. Zamki w Polsce za Kazimierza Wielkiego, red. A.Bocheńska, P. Mrozowski, Warszawa 2019.
Leksykon zamków w Polsce, red. L.Kajzer, Warszawa 2003.
Moskal K., Zamki w dziejach Polski i Słowacji, Nowy Sącz 2004.