The Demak invasions of Malacca were a series of military expeditions launched by the Demak Sultanate against Portuguese Malacca following its capture in 1511.
The fall of Malacca in 1511 AD to the Portuguese actually provided significant benefits for trade activities in the capital of Demak. However, this did not mean there was no concern or awareness regarding their presence.
The Portuguese domination of the strait made many trading ships hesitant to pass through Malacca when transporting goods, fearing that their cargo would be plundered. As a result, traders from the Nusantara region sought alternative routes for trade, opting to pass through the Sunda Strait and then westward along the western coast of Sumatra.
In 1512, Raden Patah, the Sultan of Demak, launched an attack on Malacca to prevent the Portuguese from entering the region. However, the attempt failed, and by 1513, the Portuguese had successfully seized Malacca.
In A.D. 1513 (Heg. 919), Pati Unus, a Malay chief from Java, launched an attempt to reclaim Malacca from the Portuguese. He set sail with a fleet of 90âÂÂ100 ships and an army of 5,000 troops, later reinforced to 12,000.
Malacca was under the governor Fernão Pires de Andrade, who, with three hundred and fifty Europeans and some natives aboard seventeen galleys, confronted Pati Unus's fleet. The Portuguese drove the forces toward the Moar river, where they sunk and burned most of the vessels. Pati Unus barely escaped and had lost eight thousand men and sixty of his largest ships.
After succeeding Sultan Raden Patah as the second Sultan of Demak, Pati Unus led a second expedition to Malacca with 375 ships in 1521. However, this second assault on the Portuguese would fail, and the Sultan would die in battle, earning him the title "Pangeran Sabrang Lor".
The success of the Portuguese defense of Malacca gave them free control over spice trade ports in the Nusantara Archipelago.
Meanwhile, the newly crowned Sultan of Demak, Trenggana, instructed Fatahillah to conquer Banten. After doing so, he proceeded to conquer Sunda Kelapa and expelled the Portuguese from Java.