Question: Can the funeral prayer be performed at the time of sunset?
Answer: It is narrated from Uqbah ibn Amir (may Allah be pleased with him):
«ثلاث ساعات كان رسول الله صلى الله عليه وسلم ينهانا ان نصلي فيهن، او نقبر فيهن موتانا: حين تطلع الشمس بازغة حتى ترتفع، وحين يقوم قائم الظهيرة حتى تميل، وحين تضيف الشمس للغروب حتى تغرب»
Abu Dawud 3192, Nasa’i 561, Tirmidhi 1030, Ibn Majah 1519, Abu Awanah 386/1, Bayhaqi 32/4, Musnad Tayalisi 1001, Musnad Ahmad 152/4
“There are three times at which the Messenger of Allah ﷺ forbade us to pray or to bury our dead: when the sun is clearly rising until it has risen high, when it is directly overhead at midday until it has declined, and when it inclines towards setting until it has set.”
Allamah al-Albani (may Allah have mercy on him) says:
«ولا تجوز الصلاة على الجنازة فى الاوقات الثلاثة التى تحرم الصلاة فيها الا لضرورة لحديث عقبة بن عامر»
“It is not permissible to perform the funeral prayer in the three times in which prayer is forbidden, except out of necessity, because of the hadith of Uqbah ibn Amir (may Allah be pleased with him).”
Muhammad ibn Abi Harmalah says:
“Zaynab bint Abi Salamah died, and at that time the governor of Madinah was Tariq. Her funeral was brought after the Fajr prayer and was placed in al-Baqi’, and Tariq used to pray Fajr in the darkness. Ibn Abi Harmalah says: I heard Abdullah ibn Umar (may Allah be pleased with them both) saying to the family of Zaynab: ‘Either pray the funeral prayer now, or delay it until the sun has risen high.'”
The funeral prayer is to be performed after Asr and after Fajr, when these two prayers are performed in their proper time, that is, Fajr is prayed in the darkness and Asr is prayed before the sun turns yellow. Ali (may Allah be pleased with him) informed Ziyad:
«ان جنازة وضعت فى مقبرة اهل البصرة حين اصفرت الشمس فلم يصل عليها حتٰي غربت الشمس فامر ابو برزة المنادي فنادٰي بالصلاة ثم اقامها فتقدم ابو برزة فصلٰي بهم المغرب وفي الناس انس بن مالك وابوبرزة من الانصار من اصحاب النبى صلى الله عليه وسلم صلوا على الجنازة»
“A funeral was placed in the cemetery of the people of Basrah at the time when the sun was turning yellow, and the funeral prayer was not performed over it until the sun had set. Abu Barzah (may Allah be pleased with him) ordered the muezzin to call the adhan for the prayer. He called the adhan, then the iqamah, and Abu Barzah (may Allah be pleased with him) stepped forward and led them in the Maghrib prayer. Among the people were Anas ibn Malik and Abu Barzah the Ansari (may Allah be pleased with them both). Then they prayed the funeral prayer.”
Abd al-Rahman ibn Humayd ibn Abd al-Rahman ibn Awf says:
«واتي بجنازة رافع بن خديج بعد صلاة الفجر فسمعت عبدالله بن عمر يقول صلوا علٰي صاحبكم الآن والا فاخروا حتٰي تطلع الشمس»
“The funeral of Rafi’ ibn Khadij was brought after the Fajr prayer. I heard Abdullah ibn Umar (may Allah be pleased with them both) say: ‘Pray the funeral prayer over your companion now, otherwise delay it until the sun rises.'”
From the above hadiths and narrations of the Companions it is known that when the sun is rising, or is directly overhead, or is close to setting, the funeral prayer and the like should not be performed. This is the view of Imam Ahmad, Imam Ishaq, Imam Malik, Imam al-Awza’i, Imam Abu Hanifah (may Allah have mercy on them) and other imams.
Whereas Imam al-Shafi’i (may Allah have mercy on him) says:
“There is no harm in performing the funeral prayer in the times in which prayer is disliked.”
Allamah Abd al-Rahman Mubarakpuri (may Allah have mercy on him) says:
“If it is said that the funeral prayer is also a prayer and every prayer is forbidden at these times, then how did Imam al-Shafi’i (may Allah have mercy on him) say that there is no harm in performing the funeral prayer at these times? The answer will be that according to Imam al-Shafi’i (may Allah have mercy on him), not every prayer is forbidden at these times, but only those prayers which have no reason behind them; prayers that have a reason are permissible at these times, and the funeral prayer is among the prayers that have a reason.”
Imam al-Khattabi (may Allah have mercy on him) says:
“People have differed regarding the permissibility of performing the funeral prayer and burying the dead in these three times. Most of the people of knowledge hold that performing prayer at these times is disliked. This is the opinion of Ata, al-Nakha’i, al-Awza’i, al-Thawri, the Ahl al-Ra’y, Ahmad and Ishaq ibn Rahwayh (may Allah have mercy on them), whereas according to Imam al-Shafi’i (may Allah have mercy on him), prayer and burial of the dead are valid and permissible at any time of the day or night, and the opinion of the majority is preferable because of its agreement with the hadith.”
Imam Ibn al-Mundhir (may Allah have mercy on him) also accepted this view.
And in the view of the writer too, this is the more appropriate view, because it is supported by the hadith of Uqbah ibn Amir (may Allah be pleased with him) and the narrations of the Companions (may Allah be pleased with them). «والله اعلم»
Allamah Abd al-Rahman Mubarakpuri (may Allah have mercy on him) says:
“It is permissible to perform the funeral prayer after the Asr prayer and after the Fajr prayer. However, the funeral prayer should not be performed at the time of sunrise, at the time of sunset, and at the time when the sun stands exactly overhead at midday.”