The Java War , which the Indonesians call Diponegoro’s War ( Perang Diponegoro ), took place from 1825 to 1830. Its starting point is the refusal of Prince Diponegoro, eldest son of Sultan Hamengkubuwono II of Yogyakarta , to let the Dutch to pass the ” Great Post Road ” ( Groote Postweg ) that they are building to connect the western and eastern ends of the island of Java, at the initiative of Governor General Daendels .

One of the causes of this war is the feeling of betrayal felt by some of the princes of the blood and the Javanese aristocracy towards the Dutch. The latter now forbade the nobles to rent their land at too high a price. Another cause was the question of the succession to the throne of Yogyakarta. Diponegoro was the eldest, but his mother was not the queen, so he had no right to the estate.

At first, the Diponegoro campaigns are successful. He quickly controls the center of Java and besieges Yogyakarta. Half of the Javanese nobility has made up its mind. The people support him. But Diponegoro is struggling to maintain the strength of his troops. On the other hand, the Dutch colonial army manages to enlist Minahasa soldiers of North Sulawesi then of the Netherlands. The commander of the Dutch troops, General De Kock, manages to quickly end the siege of Yogyakarta.

Diponegoro avoids row battles and practices guerrilla warfare. Ambushes and cholera decimate the Dutch troops. It was not until 1827 that the Dutch managed to gain the upper hand. The rebellion ended in 1830 when they arrested Diponegoro in Magelang , where they had invited him to negotiate a ceasefire. Diponegoro is exiled to Manado in northern Sulawesi, then to Makassar in the south of the island, where he dies. The Dutch annex the Javanese principalities.

An estimated 200,000 people died from the conflict, including 15,000 soldiers, including 8,000 Europeans. The majority of the dead are peasants hungry for crop destruction.

The end of the Java War inaugurates a new period of peace that will allow the Dutch colonial government to begin the economic exploitation of the island. Governor General van den Boschinitiates a system of forced cultivation ( cultuurstelsel ) by which the Javanese peasant must either devote a quarter of his land to commercial productions whose proceeds go to the government, or a quarter of his time working in government plantations.

Moreover, the Dutch have become cautious in their relations with the Javanese aristocracy. To compensate for the loss of income resulting from the limited rent on his land, the Dutch recruit members of noble families to fill the positions of modern administration they put in place. These officials, in addition to their salary, will receive a percentage on crops and plantation products.

Finally, the pacification of Java will allow the Dutch to devote themselves to the submission of other indigenous states to Sumatra (including the Sultanate of Palembang ), Borneo ( Sultanate of Pontianak ) and other islands of the Indonesian archipelago.