In 1793 it was annexed by Prussia in the Second Partition of Poland, in 1807 regained by Poles and included within the short-lived Duchy of Warsaw, in 1815 re-annexed by Prussia, and from 1871 to 1918 was also part of Germany. The population took part in Polish uprisings of 1830–1831 and 1848.
The territory was incorporated into Prussian control in 1793 as a result of the Second Partition of Poland, only to be reclaimed by Poles and placed under the short-lived Duchy of Warsaw. It then reverted back to Prussia in 1815 before becoming part of Germany from 1871 to 1918. The local population played a role in two Polish rebellions, one in 1830-1831 and another in 1848.