In 1772 the town was annexed by the Kingdom of Prussia in the First Partition of Poland. The population of the town numbered 1831. In 1807 Guttstadt was seized in turn by the French, the Prussians and the Russians. In the Battle of Guttstadt-Deppen on 5 and 6 June 1807, the Russian army under General Levin August, Count von Bennigsen attacked Marshal Michel Ney's French corps. Though badly outnumbered, Ney conducted an effective rear guard action and escaped to the southwest across the Pasłęka River with most of his troops. Napoleon Bonaparte spent a night in the Collegiate between 8 and 9 June 1807. The Collegiate chapter was dissolved and its properties were parcelled out on the strength of the edict issued by King Frederick William III of Prussia on 5 October 1810. In the years 1830-1834 the evangelical church was erected, mainly thanks to the donations of Frederick William III.