Swedish king Charles XII stayed in the town from February 1713 to October 1714 after his flight from the Battle of Poltava, but otherwise the town became an unimportant provincial backwater in early modern times.