The earliest inscription found during this period is the tombstone of Ibnu Mahmud in Leubok Tuwe, Meurah Mulia,
North Aceh. The tombstone dated from
Dhul Hijjah 622 Hijri or 1226 CE. The inscription mentioned that Ibn Mahmud was a
shahid.
Arab and
Indian
Muslims had traded in Indonesia and
China for many centuries. A Muslim tombstone in eastern
Java bears a date corresponding to 1082. But substantial evidence of
Islam in Indonesia begins only in northern
Sumatra at the end of the 13th century. Two small Muslim trading kingdoms existed by that time at Pasai and
Peureulak or Perlak. A 1297 royal tomb at Samudra is inscribed entirely in
Arabic. By the 15th century several harbour kingdoms developed, all ruled by local Muslim princes, from the north coast of Java and elsewhere to as far east as
Ternate and
Tidore in
Maluku.
Marco Polo spent five months here, he had Ferlec, Basma, and Samara (Samudera) mentioned in his travel story. Another famous traveller
Ibn Battuta on his way to
China stayed 15 days at Samudera. The establishment of the first Muslim centres in Indonesia was probably a result of commercial circumstances. By the 13th century the collapse of
Srivijayan power, drew foreign traders to harbours on the northern Sumatran shores of the
Bay of Bengal, safe from the pirate lairs at the southern end of the
Strait of Malacca. Northern Sumatra had a hinterland rich in
gold and forest produce, and
pepper was being cultivated at the beginning of the 15th century. It was accessible to all the merchants of the archipelago who wanted to meet ships from the
Indian Ocean. during
his voyage to Pasai. In the year 1345,
Ibn Battuta, a
Moroccan traveller visited Samudra Pasai where he notes in his travel log that the ruler of Samudera Pasai was a pious Muslim, who performed his religious duties in utmost zeal. The
madh'hab he observed was Imam
Al-Shafi'i. At that time Samudera Pasai was the end of
Dar al-Islam for no territory east of this was ruled by a Muslim ruler. He praised the kindness and hospitality demonstrated by the sultan of Samudera Pasai. Here he stayed for about two weeks in the wooden walled town as a guest of the sultan, and then the sultan provided him with supplies and sent him on his way on one of sultan's own
junks to China. By the 13th century, Muslim merchants and religious scholars from the Samudera Pasai Sultanate reached the southern Philippine islands, including Basilan and Sulu, through regional maritime trade networks connecting Sumatra with Borneo and the Sulu Sea. Through these contacts, Samudra-Pasai contributed to the introduction and early spread of Islam in these communities. The
Hongwu Emperor of China's
Ming dynasty listed Samudera in his admonition the
Huang-Ming Zuxun as one of 14 countries which the Ming should not launch a military campaign against. By the end of the 14th century, Samudra-Pasai had become a wealthy commercial centre, giving way in the early 15th century to the better protected harbour of
Malacca on the south-west coast of the
Malay Peninsula.
Majapahit attacked and looted the place in the middle of the 14th century. Pasai's economic and political power depended almost entirely on foreigners. Muslim traders and teachers probably participated in its administration from the beginning and were bound to introduce religious practices that made them feel at home. The first Muslim beachheads in Indonesia, especially Pasai, were to a considerable extent genuine Muslim creations that commanded the loyalty of the local population and encouraged scholarly activities. Similar new harbour kingdoms formed on the northern coast of Java.
Tomé Pires, author of the
Suma Oriental, writing not long after 1511, stresses the obscure ethnic origins of the founders of
Cirebon,
Demak,
Japara, and
Gresik. These Javanese coastal states served commerce with India and China and especially with Malacca, an importer of Javanese
rice. The rulers of Malacca, despite their prestigious Srivijayan origin, accepted Islam precisely to attract Muslim and Javanese traders to their port. Pires also mentions that while Pasai used to be a major rival of trade with Malacca, after the mid-15th century, much trade activity was lost to the benefit of Malacca. The
Portuguese occupied Pasai in 1521, 10 years after their conquest of Malacca. Through the Portuguese, the place become known in
Europe as
Pacem. The Portuguese garrison evacuated Pasai in 1524 and the first
Sultan of Aceh,
Ali Mughayat Syah,
annexed the territory. ==List of rulers==