It was under the control of the Lords of Wartenberg from 1305 until 1534, when it was bought by the rich Lord Rudolf von Bünau. This family introduced Protestantism to the region and the town flourished; however the Protestant belief was suppressed by the Habsburg kings in the course of the Counter-Reformation, and the Bünaus were driven out upon the 1620 Battle of White Mountain. In 1628 they sold the town to the Barons of Thun; it was devastated several times during the Thirty Years' War.