Nidzica ńi'dźica (former Nibork; Neidenburg ˈnaɪ̯dn̩bʊrk) (Old Prussian: Nīdaspils) is a town in the Warmian-Masurian Voivodeship of Poland, lying between Olsztyn and Mława, in Masuria. The capital of Nidzica County, its population in 2017 was 13,872.
The settlement was originally founded by Old Prussians who established a small fortified fort and were subsequently invaded by Teutonic Knights in 1355, who then erected a small castle around 1376 and implemented German Town Law in the settlement after 1381. After the victorious Battle of Grunwald (1410) the town remained in Polish hands for three months. It was again captured by the Poles in 1414.
From 1444 Neidenburg was a member of the Prussian Confederation, at which request in 1454 Polish King Casimir IV Jagiellon signed the act of incorporation of the region to the Kingdom of Poland. The Polish army then peacefully entered the town and Adam Wilkanowski became the commander in the castle. In 1455 a Teutonic attack was repulsed and the town remained within Poland for the rest of the war. The incorporation of Nidzica to Poland was confirmed in the peace treaty signed in Toruń in 1466, but two years later the town came under Teutonic rule, remaining under Polish suzerainty as a fief. It then became part of the Duchy of Prussia, also a vassal state of Poland, after the secularization of the Order's Prussian territories in 1525. After 1525, Neidenburg was capital of the county, whose first administrator was Piotr Kobierzycki, a local Polish nobleman. In 1549 the Czech Brethren settled in the town. In the 16th, 17th and 18th centuries, Polish pastors from Neidenburg published their works and translations in both Neidenburg and Königsberg (Królewiec). In 1656 the town was unsuccessfully besieged during the Northern Wars. The city suffered from fires in 1656, 1664, 1784 and 1804. In 16th century a significant part of inhabitants in surrounding countryside were Polish farmers
Neidenburg became part of the Kingdom of Prussia in 1701. Half of Neidenburg's inhabitants died from plague from 1708 to 1711.