The region was annexed from the Polish–Lithuanian Commonwealth by the Kingdom of Prussia during the First Partition of Poland in 1772. Tczew, as Dirschau, became part of the newly founded Province of West Prussia. During the Napoleonic Wars and the Polish national liberation fights the town was captured by Polish troops of General Jan Henryk Dąbrowski in 1807, but became Prussian again in 1815.