Duke Bolesław II Rogatka, the founder, had the castle documented by 1277 as a defensive point of the young Duchy of Świdnica-Jawor; behind its walls the Silesian Piasts kept their treasury. The castle passed between dukes and Bohemian kings, each era leaving its masonry, and in the sixteenth century a Renaissance rebuild wrapped the Gothic core in a new outer wall with bastions, an answer to the age of gunpowder.
The Hussites besieged it and went home without it; Swedish troops took it in 1646, the only ones who ever did. Quieter owners followed: the von Zedlitz family, then the Cistercians of Krzeszów; after the Napoleonic wars Russian soldiers sheltered here, and between the wars the ruin became a youth hostel and then a museum. Today the museum of Silesian fortresses runs knightly tournaments in season and the Castle Party festival each summer, and the town below keeps its sloped arcaded square from the eighteenth century.