The town is located at an Old Prussian settlement which received town rights in 1351 as "Schiffenburg", after the area was conquered by the Teutonic Knights. In 1372 the town was surrounded by a defensive wall with two entrance gates. In 1440 the town joined the Prussian Confederation, at which request in 1454 King Casimir IV Jagiellon signed the act of incorporation of the region to Poland. During the Thirteen Years’ War, the town was successfully defended against the Teutonic Knights, until 1461. After the Second Peace of Toruń of 1466 the town remained part of the Teutonic state, now a Polish fief. An important route connecting Warsaw and Königsberg ran through Schippenbeil, contributing to the town's prosperity. In 1710 about 50 percent of the population died of the epidemic plague and the town was largely destroyed by a fire in 1749. As the town became part of the Kingdom of Prussia in 1701, it was peripheral in the new state and wasn't able to rebuild itself and return to its former prosperity, because the trade traffic on the Warsaw-Königsberg route froze as the result of the end of Polish suzerainty over the town and the region north of the town to Königsberg. The 18th-century border of Poland ran in close proximity, south of the town. During the Napoleonic Wars, in 1806-1807, the Baroquetown hall and the old granaries were burnt down. After the Polish November Uprising from September 1831 to February 1832, interned Polish officers and soldiers stayed in the town. The Polish officer Józef Jan Giedroyć was awarded the Virtuti Militari, soon died and was buried on a hill in the town, which was later called the Giedroyć Hill. The memorial monument was destroyed after some time. Between 1871 and 1945 the area was part of Germany. In the late 19th century the town was slowly declining. Local Jews, whose community existed since the beginning of the 19th century, were imprisoned by the Germans in the Stutthof concentration camp during World War II. Also, a subcamp of Stutthof concentration camp was operated near Schippenbeil, the inmates were evacuated in January 1945 and murdered in the Palmnicken massacre. In early February 1945, the Soviets entered the almost completely abandoned city, plundered it and destroyed it. After the war it became part of Poland.