A Decisive Word on al-Khidr, peace be upon him
The position upheld by the critical scholars is clear: al-Khidr has passed away and he did not live to see Islam. Had he been alive during the time of the Prophet, peace and blessings be upon him and his family, it would have been obligatory for him—like everyone else—to believe in him and to fight at his side. In that case, he would have resided in Mecca and Medina, and his joining the Companions in jihad and in supporting the religion would have been far more fitting than appearing among a people of unbelief merely to mend their boat. He would not have concealed himself from the best community ever raised for humankind, especially when he had once moved openly among the idolaters without hiding from them.
Furthermore, the Muslims have no need of him—or of anyone like him—either for their religion or for their worldly life, for they have received their religion directly from the unlettered Prophet-Messenger, peace and blessings be upon him and his family.