Hikayat Raja-raja Pasai (حكاية راج-راج ڤاسا translated as “Chronicle of the Kings of Pasai”) is perhaps the earliest work in Malay on the first Malay-Muslim kingdom of Samudera-Pasai. In the story, Merah Silu met Muhammad in his dream and accepted conversion to Islam. The book is believed to have been composed around the late 14th or more likely early 15th century. The text of this work has a lot of parallels with the Sejarah Melayu and the history of Melaka.

It is not certain when this hikayat was first written because at that time the tradition of retelling other people's stories (as is done in oral stories) was prevalent and considered normal. Note the following excerpt from Hikayat Raja Pasai:

Once upon a time, a fairy told the story of the first king to convert to Islam, Pasai; then it was narrated by the person who owns this story, this land under the wind, Pasai was the first to bring faith in Allah and the Messenger of Allah. Then there were two kings, one named Raja Ahmad and the other named Raja Muhammad. As for the older one, Raja Ahmad. So the two brothers wanted to establish a kingdom in Samarlanga. Artifacts such as the tomb of Sultan Malik al Salih show that Pasai is located in Geudong Village , Lhokseumawe , north of Aceh , Sumatra island , Indonesia .

This text is written in Malay using handwritten Jawi script on book-shaped sheets. Researchers state that the original text was written around 1360 AD because it was contemporary with the mystical book Durru al Mazlum / Darul Mazlum by Maulana Abu Ishak.

Genre Hikayat Raja-Raja Pasai belongs to the genre of historical literature also referred to today as the Agong's work. Historical literary works usually tell the story of the founding of a state, its administrative organization, socio-cultural conditions and political patterns. This story includes the existence of a state, its development, its golden age, its defeat and collapse.

So Hikayat Raja-Raja Pasai is not a pure history textbook. On the contrary, it has been spiced up with historical elements. Elements of myth and legend are applied in historical material that requires deep interpretation to know the objectives and purposes of the author of this palace .

The Opening and Islamization of Pasai Pasai was the first state to accept Islam. Raja Ahmad and Raja Muhammad wanted to open the state of Samarlanga . Raja Muhammad got Princess Betung from a bamboo shoot. Raja Ahmad lived in Balik Rimba. He went hunting and met an old man in a surau. From the advice of the old man in the surau, Raja Ahmad got a son who was protected by an elephant . The child was named Merah Gajah. Finally Merah Gajah was married to Princess Betung. Merah Gajah and Puteri Betung had sons, Merah Silau and Merah Hasun. Merah Gajah pulled out Puteri Betung's golden hair and strange white blood came out. Puteri Betung finally disappeared. Raja Muhamad got angry and killed Merah Gajah. So Raja Ahmad invaded Raja Muhamad's country and war broke out. Both of these brother and sister kings were killed in the war. Merah Silau and Merah Hasun lived in Biruan. Merah Silau held back the trap and got roundworms that turned into gold and silver. Merah Silau had the power to tame the wild buffaloes in the area. Merah Hasun was angry because he thought his brother ate roundworms and played with buffaloes, an act that disgraced the king's dignity. He chased Merah Silau away from his place. Merah Silau and his followers moved to Sungai Pasangan and to Hulu Kalang. There he met Megat Iskandar and he agreed to live in Buluh Telang. Unfortunately Merah Silau was very fond of cockfighting. Megat Sekandar and Megat Kedah were the brothers of Sultan Malikul Nasir in Rimba Jerana. Megat Sekandar wanted to make Merah Silau king but was opposed by Tun Harid Benung. When Merah Silau became king, Sultan Malikul Nasir attacked him and a long war ensued. Finally Sultan Malikul Nasir fled to Kumat. But in Kumat, Sultan Malikul Nasir was attacked by Megat Sekandar and Sultan Malikul Nasir was killed. His chieftain named Tun Harid Benung fled to the state of Barus but was captured by Raja Barus. Merah Silau became king in Rimba Jerana. Prophet Muhammad advised his companions to preach in the land of the Ocean after his death. Bring a ship and equipment and take a fakir in the land of Mengiri to convert the entire land of the Ocean to Islam. While hunting in the forest, the Red Silau dog named Si Pasai barked loudly and hugged the deer 7 times . On a hill there was an ant the size of a cat . Red Silau ate the ant and the place became a country called Semudera. Prophet Muhammad died. The Sharif who administered the city of Mecca had fulfilled the will of Prophet Muhammad. Sheikh Ismail was assigned to Semudera. He was staying in the country of Mengiri. The King of Mengiri was named Sultan Muhamad, a descendant of Saidina Abu Bakar . His young son disguised himself as a poor man and boarded the ship. The ship sailed to Semudera. Merah Silau dreamed of meeting the Prophet Muhammad. The Prophet rested his chin on his chin and closed his eyes for four hours. The Prophet taught him to recite the two words of the Shahadah. The Prophet spat into his mouth. The Prophet named him Sultan Malikul Saleh, to eat only halal animals that had been slaughtered. In 40 days, a ship from Mecca would arrive and he should accept the teachings of Islam that were brought. When Merah Silau woke up from sleep, Merah Silau found that his genitals had been circumcised and his mouth was fluent in reciting the 30 chapters of the Quran . A ship from Mecca had docked at the Samudera port in Teluk Terli. Sheikh Ismail met Sultan Malikul Saleh and asked him to recite the two words of shahadah . Fakir gave a copy of the Quran and Sultan Malikul Saleh could read it fluently. Sheikh Ismnail succeeded in converting all the people of Semudera to Islam. Sheikh Ismail appointed Sultan Malikul Saleh as the King of Semudera Darul Salam. The minister named Tun seri Kaya was given the name Sayid Ghiatuddin and Baba Kaya with the new name Sayid Semayamuddin. After completing his assignment, Sheikh Ismail sailed back to Mecca. The Sultan presented a ransom of amber , camphor , agarwood , sandalwood , frankincense , cloves , and nutmeg , about 100 bahara. Fakil Mohamad lived in Samudera teaching Islam. A tribe in the ocean refused to embrace Islam. They fled upstream to the Pasangan, now known as the Gaya people. Sultan Malikul Saleh married Princess Ganggang, the concubine of King Perlak. A Keling from the Keling Continent has been working on a gold mine in the Ocean. Sultan Malikul Saleh had a son named Sultan Malikul Tahir. The state of Pasai was opened and Sultan Malikul Tahir became the king there. Sultan Malikul Tahir had two sons, Sultan Malikul Mahmud and Sultan Malikul Mansur. Sultan Malikul Tahir died. Sultan Malikul Saleh handed over his grandson Sultan Malikul Mahmud to be looked after by Sayid Ali Ghiatuddin and Sultan Malikul Mansur was looked after by Sayid Semyamuddin. Sultan Malikul Saleh ruled Sultan Malikul Mahmud in Pasai and Sultan Malikul Mansur in Samudera Darul Salam. Before Sultan Malikul Saleh passed away, his Majesty had bequeathed that both Prime Ministers and his two grandsons should govern fairly and equitably according to Islamic law . The Pasai government refused to pay tribute to the King of Siam as requested. A Siamese warlord named Talak Sejang attacked Pasai. Siam was defeated and Talak Sejang was killed. Sultan Malikul Mahmud had two sons and two daughters. His son was named Sultan Ahmad Perumudal Perumal. While Sultan Malikul Mahmud was hunting, Sultan Malikul Mansur came to Pasai and took a woman from the Pasai palace. Sultan Maikul Mahmud scolded Prime Minister Sayid Semayamuddin for not stopping his younger brother's incestuous act. The Prime Minister of Pasai had died and was replaced by Tun Perpatih Tulus Tukang Segara and they planned to kill Sayid Semayamuddin. Sultan Malikul Mahmud held a circumcision ceremony for his son Sultan Ahmad Perumudal Perumal and invited Sultan Malikul Mansur and the Prime Minister of the Sea, Sayid Semayamuddin. Instead, Sultan Malikul Mansur was arrested and exiled to the state of Temiang. Meanwhile, Sayid Semayamuddin was killed, his head thrown into the sea, his body impaled in Kuala Pasai. But strangely, the head followed Sultan Malikul Mansur's boat. Therefore, Sultan Malikul Mansur asked Sultan Malikul Mahmud to bury the body of Sayid Semayamuddin who was impaled in Padang Maya. After repenting, Sultan Malikul Mahmud invited Sultan Malikul Mansur to Pasai again. But on the way to Pasai, Sultan Malikul Mansut died on the tomb of Sayid Semayamuddin. Sultan Malikul Mahmud became increasingly depressed and fell ill. He made a will for his son Sultan Ahmad Perumudal Perumal to become the king of Pasai.

Pasai under Sultan Ahmad Perumudal Perumal Sultan Ahmad Perumudal Perumal became the king of Pasai after the death of Sultan Malikul Mahmud. A jogi from Benua Keling appeared before him and called Sultan Ahmad Perumudal Perumal and the title remained. Sultan Ahmad had 30 children but only 5 of them were from the same mother and father, namely Tun Beraim Bapa , Tun Abdul Jalil, Tun Abdul Fadil, Tun Medan Peria and Tun Takiah Dara. Sultan Ahmad had 4 senior ministers, namely Tulus Agung Tukang Sekara, Baba Mentuha, Sulaiman Dendang Air and Tun Syah Ala Kota. Sultan Ahmad Perumudal Perumal had an excessive lust because he lusted after his own virgin daughters, Tun Takiah Dara and Tun Medan Peria. To prevent bad things from happening, Tun Beraim Bapa brought his two younger sisters to Tukas to live with him. This caused Sultan Ahmad to become even more angry and wanted to realize his greedy desires. Four Keling warriors came to compete in strength ( wrestling ) in Pasai and behaved like thugs . Tun Beraim Bapa, who was brave and powerful, trained with his teachers in Tukas. The war drums from Tukas disturbed the sleep of Sultan Ahmad Perumudal Perumal in Pasai. His Majesty was angry and told Dara Zulaikha Tingkap about his intention to kill Tun Beraim Bapa. Tun Beraim Bapa succeeded in defeating the Keling warriors and they returned to the Keling Continent. Tun Beraim Bapa had joked with Tun Fatimah Lempau while he was at his father's palace in Pasai until the Pasai palace shook. Sultan Ahmad Perumudal Perumal woke up from his sleep and planned a strategy to have Tun Beraim Bspa killed. Sultan Ahmad ordered Tun Beraim Bapa to dive into the Pasai River and ordered the hulubalang to cut it if it emerged. But Tun Beraim Bapa waited because the emerging chain was far away from the place. Sultan Ahmad ordered Tun Beraim Bapa to remove the log that was stuck to Sultan Ahmad's boat. Tun Beraim Bapa managed to free the stuck boat and did not drown. Sultan Ahmad ordered Tun Beraim Bapa to eat cucur peniaram (poisonous) made by the Seri people. The dogs and chickens that ate the cucur peniaram died of poisoning. His two younger brothers Tun Medan Peria and Tun Takiah Dara also died of poisoning from eating cucur peniaram. They were buried at Bukit Fudul Allah . Tun Beraim Bapa, who did not want to disobey, ate the poisonous cucur peniaram and fell ill. Tun Beraim Bapa, who was very hot, dived into Lubuk Turai. A bull snake was caught and eaten but his illness did not heal. Then Tun Beraim Bapa threw a spear and the spear pierced between the graves of his two brothers. Tun Beraim Bapa finally died and was buried where the spear pierced. Sultan Ahmad was very happy with the death of his son. During the absence of Sultan Ahmad Perumudal Perumal, Tun Abdul Jalil ruled the Pasai kingdom.

Expansion of Majapahit Power