Likewise, striving to secure medical treatment for him—provided that such efforts will, or are expected to, influence his conduct, prompt his repentance and bring him back from what he is upon—is a praiseworthy act.
As for accompanying his funeral procession should he die while you know that he never performs the prayer, having wilfully and totally abandoned it, then it is not permissible for you to follow his funeral. By dying in that state he has died upon disbelief, and a Muslim may not follow the funeral of a disbeliever, perform the funeral prayer over him, or even bury him in the Muslims’ graveyard. If it is established that he never prayed, deliberately gave up the prayer and died on that, he has died the death of a disbeliever—may Allah protect us—so it is impermissible to accompany his funeral.
***
Sitting with and Socialising with One Who Has Abandoned the Prayer
Question: Is it permissible for me to sit with and join in the company of someone who persists in abandoning the prayer?
Answer: You are not allowed to sit with him or share food and drink with him unless you are advising him, censuring him for what he is doing, and hoping that Allah will guide him through you. If you do that, then it is permissible—indeed obligatory—for you to continue, because this is part of forbidding evil and calling to Allah, hoping that Allah guides him at your hands.
But if you merely keep him company—sitting, eating and drinking with him—without any reproach while he continues to neglect the prayer, or persists in some other major sin, then it is not permissible for you to associate with him.
Allah cursed the Children of Israel for behaviour like this. He, the Exalted, says: “Those among the Children of Israel who disbelieved were cursed by the tongue of David and of Jesus, son of Mary; that was because they rebelled and transgressed. They would not forbid one another from the evil they committed.” (Al-Ma’idah 5:78–79).