The Batavian Revolution (De Bataafse Revolutie) was a time of political, social and cultural turmoil at the end of the 18th century that marked the end of the Dutch Republic and saw the proclamation of the Batavian Republic. The period of Dutch history that followed the revolution is referred to as the "Batavian-French era" (1795–1813) even though the time spanned was only 20 years, of which three were under French occupation under Napoleon Bonaparte.
By the end of the 18th century, the Netherlands found themselves in a deep economic crisis, caused by the devastating Fourth Anglo-Dutch War. During this time, the banks of the Dutch Republic held much of the world's capital. The government-sponsored banks owned up to 40% of Great Britain's national debt. The people of the Netherlands grew increasingly discontent with the authoritarian regime of the stadtholder, William V. This concentration of wealth led to the formation of the Dutch Patriots by a minor Dutch noble named Joan van der Capellen tot den Pol, who were seeking to reduce the amount of power held by the stadtholder.
Thus, a division emerged between the Orangists, who supported the stadtholder, and the Patriots who, inspired by the ideals of the Enlightenment, desired a more democratic government and a more equal society. The Patriots built support from most of the middle-class, and founded militias (Exercitiegenootschappen) of armed civilians which between 1783 and 1787 managed to take over several cities and regions in an effort to force new elections which would oust the old government officials. The Patriots held Holland and the city of Utrecht, while the Orangists held the states of Guelders and Utrecht (outside of its capital city).
In 1785, stadtholder William V fled his palace in the west of the country for Nijmegen in the east, as the States of Holland were not willing to send their troops to fight the Patriots. In May 1787, the stadholder's troops were defeated by the militia of Utrecht near Vreeswijk.