According to one narration, Al-Khadir is a direct offspring of Adam, peace be upon him. Others have mentioned that he is Balya’ bin Malkan whose linage goes back to Sam bin Nuh, peace be upon him. Hence, according to both narrations he was born before prophet Ibrahim, because Ibrahims grandfather and Al-Khadir were first cousins. He was called Al-Khadir (a word extracted from the word Arabic for green), because he once sat arid piece of land that had no plants, and as a result it turned leafy, swaying with greenness. He was also known as Abul-^Abbas. Wherever he prayed the earth around him would turn green, by the will of Allah, as an endowment from God to him indicating his high rank in piety.
It was narrated that when Prophet Adam was on his deathbed, he summoned his children and said to them, “Oh sons, Allah is going to inflict a severe torture upon the people”. Then he informed them about the deluge which was to take place. He entrusted them to carry his body with them in the ark and then bury him in a specific cave near the area of ash-Sham. This request was passed down from one generation to the next until Nuh received the revelation. Before the flood started, Nuh took Adam’s body and carried it with them in the ark. The earth overflowed with the water for a period of time.
When the flood ended Nuh was in Babylon, and asked his three sons Ham, Sam and Yafith to carry Adams body to the cave which he had asked to be buried in. They said, “The land is deserted and we will not find our way; let us wait until there is a greater population of people”. Nuh replied “ Adam supplicated that the person who buries him will live until the Day of Judgement”. Adams body was passed down from one generation to another until Al-Khadir came and carried out Adam’s wish by burying him in the specified cave. As a result, Allah granted Al-Khadir long life, so he lives for as long as Allah wills.
Another saying regarding his long life involves Dhul Qarnayn al-Akbar. Dhul Qarnayn was a pious man and a God-fearing waliy who owned vast lands stretching from east to west. Rafa’il, an honoured angel and friend of Dul Qarnayn, would visit him from time to time.
On one of these occasions, Dhul Qarnayn said, “Oh Rafa’il, I hope that Allah will extend my life so that I can excel in obeying and worshipping Him truly as He deserves.” Rafa’il said, “ Is this really what you would like?” When Dhul Qarnayn replied. ‘Yes’, Rafa’il said, “ There is a spring called the ‘Spring of life’. The one who drinks from it will be granted longevity and will live until God wills for him to die”. Dhul Qarnayn eagerly asked, “Do you know where this spring is?” Rafa’il said, “No, but we (the angels) talk amongst ourselves in the skies that Allah created a dark place on earth that no human or Jinn has ever reached, and we think that the spring is in that dark place”.
Dhul Qarnayn gathered the scholars and asked them about the ‘Spring of life’. They all replied that they had not heard of it. He then asked; “During your studies, were any of you taught that Allah created a dark place on earth?” One of the scholars replied. “ Why do you ask?” Dhul Qarnayn told him what the angel said, and the scholar responded that he had read about this dark place in Adam’s will and that it is towards the East where the sun rises.
Dhul Qarnayn prepared an army, and appointed al-Khadir, peace be upon him to command it. They travelled for 12 years until they reached the edge of darkness only to find that it was not a darkness caused by night, rather it was caused by heavy fog.
Dhul Qarnayn chose 2000 horsemen from his army, and appointed Al-Khadir as their commander. He ordered them to search for the ‘Spring of Life’. They marched until they reached a valley; there Al-Khadir stopped them and went down on his own towards the valley, where he found himself at the edge of a spring. He took off his clothes only to find that the water was whiter than milk and sweeter and honey. He drank from it, made wudu, and bathed. He then put his clothes back on and returned. As for Dhul Qarnayn, he did not find the spring, because he lost his way in the darkness.
Al-Khadir is an honourable Prophet who was granted long life. In the beginning of his life, he used to live amongst the people, but the Allah made the surface of the water like walking ground for him. Until this day he lives by himself on the surface of the sea, and is hidden from people’s sight. With the exception of a few, Allah has blocked people from seeing him. Hence, he might come to a place and only one person among all those present would see him. Prophet Musa has seen him as well as some great Waliys.