In 1538 Nicolaus Copernicus visited the town when he accompanied Bishop Johannes Dantiscus. The 16th century was a period of peace, which ended abruptly with Swedish invasion in 1626. The Swedes overran the town several times but the inhabitants suffered most severely during the Deluge in the years 1655-1660.