The Messenger of Allah ﷺ said, "The boy whom Khidr killed was created a disbeliever by nature, and had he lived, he would have overwhelmed his parents with rebellion and disbelief."
قال رسول الله ﷺ: إن الغلام الذي قتله الخضر طبع كافرا، ولو عاش لأرهق أبويه طغيانا وكفرا.
Muslim reported it in the Book of Predestination (2661) from Abdullah bin Maslama bin Qanab, who said, Mutamir bin Sulayman narrated to us, from his father, from Raqaba bin Masqala, from Abu Ishaq, from Saeed bin Jubayr, from Ibn Abbas, from Ubayy bin Kaab, and he related it.The two sheikhs also narrated it, Bukhari in the Book of Tafsir (4727), and Muslim in the Book of Virtues (2380), both from the hadith of Sufyan bin Uyayna, from Amr bin Dinar, from Saeed bin Jubayr, with his chain of transmission, in a lengthy account that will come in its proper place.In it, it states, "While the two of them were walking along the shore, a boy suddenly appeared playing with other boys. Khidr took hold of his head and pulled it off with his hand, killing him. Musa said, "Have you killed an innocent soul who has not killed another? You have certainly done a horrible thing" [Kahf 18:74]."