Law enforcement in Poland consists of the Police (Policja), City Guards (Straż Miejska, a type of municipal police), and several smaller specialised agencies. The Prokuratura Krajowa (the Polish public prosecutor) and an independent judiciary also play an important role in the maintenance of law and order.
During the period of the Polish–Lithuanian Commonwealth's existence, most law enforcement was undertaken by a group of nobles of varying degrees of importance who possessed private armies and who, in return for political power and a place within the nation's social hierarchy, swore their allegiance, and that of their mercenary troops, to the king. As a result of the enduring power of a number of powerful 'magnates' within the social hierarchy, relative weakness of the 'elected' monarchs and continued existence of the feudal system in Polish society, centralised rule of law and enforcement of the same did not truly exist until the 1791 adoption of the 3 May Constitution.
The Constitution aimed to weaken the golden freedoms of the upper classes and redistribute a portion of their power amongst the mercantile middle classes. In addition to this, the establishment of a majority-voting Sejm and increased centralisation of sovereign power under the authority of the king, led to the establishment of a standing army, provided for by the state and subordinate only to the king and authorities of the national government.
As a result of the 1772–95 partitions of Poland, and subsequent rule of the partitioning powers (Austria-Hungary, Germany and Russia), the authority of King Stanisław August collapsed, and the former territories of the commonwealth came under the direct supervision of their partitioning powers' law enforcement services.