Who has precedence in leading the funeral prayer if the deceased has relatives present?
General Chapter
Al-Mughni
Book of Funerals
Primary text
The ruler (*Imam*) has the right to lead the funeral prayer over the deceased. This is supported by narrations concerning Al-Hasan leading the prayer over Al-Hussain, and Sa'id ibn Al-Aas leading the prayer over Umm Kulthum in the presence of senior Companions who did not object, indicating consensus that the Imam's right supersedes the relatives. This is because the funeral prayer is a communal prayer, and the Imam is given precedence in leading all communal prayers, just as the Prophet and the Caliphs led funerals without seeking permission from the deceased's relatives.
Supporting text
Al-Shafi'i, in one opinion, prioritizes the heir (*wali*) based on analogy with his precedence in marriage, relying on the order of paternal relatives.