The Constitution of 3 May 1791, titled the Government Act, was a written constitution for the Polish–Lithuanian Commonwealth that was adopted by the Great Sejm that met between 1788 and 1792. The Commonwealth was a dual monarchy comprising the Crown of the Kingdom of Poland and the Grand Duchy of Lithuania; the new constitution was intended to address political questions following a period of political agitation and gradual reform that began with the Convocation Sejm of 1764 and the election that year of the Commonwealth's last monarch, Stanisław August Poniatowski. It was the first codified, modern constitution (possessing checks and balances and a tripartite separation of powers) in Europe and the second in the world, after that of the United States.
The Constitution sought to implement a more effective constitutional monarchy, introduced political equality between townspeople and nobility, and placed the peasants under the government's protection, mitigating the worst abuses of serfdom. It banned pernicious parliamentary institutions such as the liberum veto, which had put the Sejm at the mercy of any single deputy, who could veto and thus undo all the legislation adopted by that Sejm. The Commonwealth's neighbours reacted with hostility to the adoption of the Constitution. King Frederick William II of Prussia broke the Prussian alliance with the Commonwealth, joining with Imperial Russia under Catherine the Great and the anti-reform Targowica Confederation of Polish-Lithuanian magnates, to defeat the Commonwealth in the Polish–Russian War of 1792.
The 1791 Constitution was in force for less than 19 months. It was declared null and void by the Grodno Sejm that met in 1793, though the Sejm's legal power to do so was questionable. The Second and Third Partitions of the Commonwealth (1793, 1795) ultimately ended Poland's and Lithuania's sovereign existence until the close of World War I in 1918. Over the ensuing 123 years, the legacy of the 1791 Constitution helped sustain Polish and Lithuanian aspirations for the eventual restoration of their sovereignty. In the words of two of its principal authors, Ignacy Potocki and Hugo Kołłątaj, the 1791 Constitution was "the last will and testament of the expiring Homeland".
Polish constitutionalism can be traced to the 13th century, when government by consensus and representation was already well established in the young Polish state. The emergence of parliamentary bodies, the sejm and sejmiki, followed in the first half of the 16th century. By the 17th century, Poland's legal and political tradition was characterized as parliamentary institutions and a system of checks and balances on state power, which was itself limited by decentralization. The idea of a contractual state embodied in texts like the Henrician Articles and the Pacta conventa; the concept of individual liberties; and the notion that the monarch owed duties to his subjects, can be noted. This system, which primarily benefited the Polish-Lithuanian nobility (szlachta), came to be known as the "nobles' democracy".
The 1791 Constitution was a response to the increasingly perilous situation in the Polish–Lithuanian Commonwealth, which had been a major European power only a century earlier and was still the largest state on the continent. In the 1590s, at the peak of the nobles' democracy, King Sigismund III Vasa's court preacher — the Jesuit Piotr Skarga — had condemned the weaknesses of the Commonwealth. In the same period, writers and philosophers such as Andrzej Frycz Modrzewski and Wawrzyniec Grzymała Goślicki, and the egzekucja praw (Execution-of-the-Laws) reform movement led by Jan Zamoyski had advocated political reforms. In 1656, in what came to be known as the Lwów Oath, Sigismund's son King John II Casimir Vasa made a solemn vow on behalf of the entire Polish-Lithuanian Commonwealth that he would free the Polish peasants "from the unjust burdens and oppression." As he was struggling with the Sejm, in 1661 John Casimir — whose reign saw highly destructive wars and obstructionism by the nobility — correctly predicted that the Commonwealth was in danger of a partition by Russia, Brandenburg and Austria.
As the Sejm failed to implement sufficient reforms, the state machinery became increasingly dysfunctional. A significant cause of the Commonwealth's downfall was the liberum veto ("free veto"), which, since 1652, had allowed any Sejm deputy to nullify all the legislation enacted by that Sejm. As a result, deputies bribed by magnates or foreign powers — primarily from the Russian Empire, the Kingdom of Prussia and France, which had an ongoing revolution — or deputies who believed they were living in an unprecedented "Golden Age" paralysed the Commonwealth's government for over a century. The threat of the liberum veto could only be overridden by the establishment of a "confederated sejm", which was immune to the liberum veto. Declaring that a sejm either constituted a "confederation" or belonged to one was a contrivance prominently used by foreign interests in the 18th century to force a legislative outcome.
By the early 18th century, the magnates of Poland and Lithuania controlled the state, ensuring that no reforms that might weaken their privileged status (the "Golden Freedoms") would be enacted. The ineffective monarchs who were elected to the Commonwealth throne in the early 18th century, Augustus II the Strong and Augustus III of Poland of the House of Wettin, did not improve matters. The Wettins, used to the absolute rule practiced in their native Saxony, tried to govern through intimidation and the use of force, which led to a series of conflicts between their supporters and opponents — including another pretender to the Polish-Lithuanian throne, King Stanisław Leszczyński. Those conflicts often took the form of confederations — legal rebellions against the king permitted under the Golden Freedoms — including the Warsaw Confederation (1704), Sandomierz Confederation, Tarnogród Confederation, Dzików Confederation and the War of the Polish Succession. Only 8 out of 18 Sejm sessions during the reign of Augustus II (1694–1733) passed legislation. For 30 years during the reign of Augustus III, only one session was able to pass legislation. The government was near collapse, giving rise to the term "Polish anarchy", and the country was managed by provincial assemblies and magnates.
Other reform attempts in the Wettin era were led by individuals such as Stanisław Dunin-Karwicki, Stanisław A. Szczuka, Kazimierz Karwowski and Michał Józef Massalski; these mostly proved to be futile.
The Enlightenment greatly affected the thinking of influential Commonwealth circles during the reign (1764–1795) of its last monarch, Stanisław II August Poniatowski. The King was an "enlightened" Polish magnate who had been a deputy to several Sejms between 1750 and 1764 and had a deeper understanding of Polish politics than previous monarchs. The Convocation Sejm of 1764, which elected Poniatowski to the throne, was controlled by the reformist Czartoryski Familia and was backed by Russian military forces invited by the Czartoryskis. In exchange for passing decrees favorable to them, the Russians and Prussians let the confederated Convocation Sejm enact a number of reforms, including the weakening of the liberum veto and its no longer applying to treasury and economic matters. A more comprehensive reform package was presented by Andrzej Zamoyski, but opposition from Prussia, Russia, and the Polish nobility thwarted this ambitious program, which had proposed deciding all motions by majority vote.
In part because his election had been imposed by Empress Catherine the Great, Poniatowski's political position was weak from the start. He proceeded with cautious reforms, such as the establishment of fiscal and military ministries and the introduction of a national customs tariff, which was soon abandoned due to opposition from Prussia's Frederick the Great. These measures had already been authorized by the Convocation Sejm; more legislative and executive improvements inspired by the Familia or the King were implemented during and after the 1764 Sejm.