- Authors

- Name
- Ahmad
- Role
- Senior Marketing Manager, Islamic education • DeenUp
بِسْمِ اللهِ الرَّحْمٰنِ الرَّحِيْمِ
In the name of God, the Most Gracious, the Most Merciful.

Quick answer
What is the dua for someone who has passed away in Islam?
The primary dua for the deceased is from the Janazah prayer: Allahumma ighfir lahu warhamhu wa afihi wa'fu anhu — O Allah, forgive him, have mercy on him, grant him safety, and pardon him (Sahih Muslim 963). Adjust to laha for a woman. This is the Prophet's authenticated formula for praying over the deceased.

When someone you love passes away, the weight of loss can make you uncertain what to do. You want to help them, to do something — and Islam answers that need directly. The connection between the living and the deceased does not end at death. Dua bridges that distance.
Making supplication for someone who has passed away is one of the clearest acts of love available to us. The Prophet ﷺ did it regularly, taught his companions to do it, and built it into the formal structure of the Janazah prayer. Understanding how and when to make this dua gives grief a direction.
What Is the Dua for Someone Who Passed Away?
The primary dua for the deceased in Islam comes from the Janazah (funeral) prayer and is authenticated in Sahih Muslim. It covers four requests that the deceased needs most: forgiveness, mercy, safety, and pardon. This supplication can be used not only during the funeral prayer but any time you want to pray for someone who has passed. It is the most direct, most authenticated formula the Prophet ﷺ taught for this purpose.
The Main Duas for the Deceased
Upon Hearing of a Death
The first response upon hearing that someone has died is the phrase Allah revealed in the Quran:
إِنَّا لِلَّهِ وَإِنَّا إِلَيْهِ رَاجِعُونَ
Inna lillahi wa inna ilayhi raji'un
"Verily, we belong to Allah, and to Him we shall return." — (Surah Al-Baqarah, 2:156)
The Quran continues: "Those are the ones upon whom are blessings from their Lord and mercy. And it is those who are rightly guided." Saying this phrase upon hearing of a death — with awareness of its meaning — is itself a form of dua, an acknowledgment of the reality that connects us all.
Our guide to the meaning of Inna Lillahi wa Inna Ilayhi Raji'un explains the full context and significance of this phrase.
The Janazah Prayer Dua
The dua recited during the third takbir of the Janazah prayer is one of the most comprehensive supplications for the deceased:
اللَّهُمَّ اغْفِرْ لَهُ وَارْحَمْهُ وَعَافِهِ وَاعْفُ عَنْهُ
Allahumma ighfir lahu warhamhu wa 'afihi wa'fu 'anhu
"O Allah, forgive him, have mercy on him, grant him safety, and pardon him." — (Sahih Muslim 963)
For a woman who has passed, replace lahu (him) with laha (her) throughout. The full version in Sahih Muslim continues with several more requests covering the deceased's grave, their sins, and their entry into Jannah. Our Islamic funeral rituals guide covers the full structure of the Janazah prayer.
The General Dua for All Deceased
For ongoing supplication — not just at the funeral but in your daily prayers — this dua covers your entire community:
اللَّهُمَّ اغْفِرْ لِحَيِّنَا وَمَيِّتِنَا
Allahumma ighfir li hayyina wa mayyitina
"O Allah, forgive our living and our deceased." — (Sunan Abu Dawud 3201)
This formula, brief as it is, can be added after any salah and covers family, friends, and community members who have passed — known and unknown to you.
Dua When Visiting a Grave
The Prophet ﷺ regularly visited the graves of believers and taught this greeting:
السَّلاَمُ عَلَيْكُمْ أَهْلَ الدِّيَارِ مِنَ الْمُؤْمِنِينَ وَالْمُسْلِمِينَ
Al-salamu alaykum ahl al-diyar min al-mu'minin wal-muslimin
"Peace be upon you, O inhabitants of the graves, among the believers and Muslims." — (Sahih Muslim 975)
You may follow this with any of the duas above, or with personal supplication for the person buried there.
What Does Islam Teach About Praying for the Deceased?
The theological foundation is clear: the Prophet ﷺ taught that when a person dies, three channels of ongoing benefit remain open — perpetual charity (sadaqah jariyah), beneficial knowledge they spread, and a righteous child who prays for them (Sahih Muslim 1631).
This hadith means that your dua for someone who has passed is not a one-time gesture. It is a sustained act of love that continues to reach them. Scholars have drawn from this that any righteous person — not only children — can make dua on behalf of the deceased with benefit.
The Prophet ﷺ himself made dua for deceased members of the community, visited Jannat al-Baqi' regularly, and prayed for the martyrs of Uhud. His practice is our model.
For a deeper understanding of how Islam frames death and what comes after, our guide to the Islamic perspective on death provides the theological grounding that makes these duas meaningful rather than mechanical.
Do you feel your duas are unanswered?
Have you read the dua properly? Learn authentic duas, understand their meanings, and call upon Allah with greater confidence through DeenUp.
Take the Dua Quiz
How to Make Dua for the Deceased Part of Your Routine
The most effective way to honor someone who has passed is to include them in your regular prayers — not only in the immediate days after death but indefinitely.
After every salah. Add Allahumma ighfir li hayyina wa mayyitina immediately after your post-prayer dhikr. It takes ten seconds and covers every Muslim who has passed.
Name them specifically. General duas are valid, but supplications that name the deceased carry particular weight. The Prophet ﷺ prayed by name for specific companions and family members. There is nothing wrong — and much to recommend — in calling on Allah for Fatima, for Ahmed, for whomever you have lost.
Give sadaqah on their behalf. The Prophet ﷺ confirmed that giving charity with the intention that its reward goes to the deceased is valid (Sahih al-Bukhari 2756). Feeding the poor, contributing to a well, paying off their debts — these all function as ongoing sadaqah.
Visit the grave. If the deceased is buried locally, visiting their grave and making dua there follows prophetic practice. It also benefits the visitor — the sight of graves is a reminder of the akhirah that sharpens the heart's priorities.
Our guide to how to deal with grief in Islam addresses the emotional dimension of loss alongside the practical — how the Islamic framework holds both sorrow and action together without suppressing either.
Related Duas for the Deceased and Their Uses
| Situation | Dua | Source |
|---|---|---|
| Hearing of a death | Inna lillahi wa inna ilayhi raji'un | Quran 2:156 |
| Janazah prayer | Allahumma ighfir lahu warhamhu... | Sahih Muslim 963 |
| General ongoing dua | Allahumma ighfir li hayyina wa mayyitina | Abu Dawud 3201 |
| Visiting a grave | Al-salamu alaykum ahl al-diyar... | Sahih Muslim 975 |
| Dua for deceased parents | Rabbighfir li wa li walidayya | Quran 14:41 |
For the specific duas for deceased parents, our guide to dua for parents who passed away covers the Quranic and hadith texts in full. And for what Islam says about the destination of the deceased and what they experience after death, our guide to what is Jannah and the Islamic perspective on death provide the full picture.
For companions in loss and for broader reflection on how Islamic faith navigates grief, DeenBack's guide on spiritual care during illness and loss and the Demi Manifest piece on faith through hardship both offer meaningful perspective from a lived-faith angle.
For the full authenticated hadith texts referenced here, Sunnah.com holds the verified collections in Arabic with English translation. For Quranic citations, Quran.com provides the complete Arabic alongside multiple translators.
Common Questions About Dua for the Deceased
Can I make dua for a non-Muslim who passed away? The majority position is that dua for forgiveness cannot be made for non-Muslims who died outside of Islam, based on Quran 9:113. However, you may make dua for Allah to guide those still living. For someone who died while a Muslim, all the duas above apply fully.
Do I have to have known the person? No. The Prophet ﷺ prayed for the martyrs of Uhud, for early believers, and for the community broadly. You can make dua for any Muslim who has passed — someone in your neighborhood, a scholar you admired, a historical figure.
Can I ask the deceased for something? Scholars distinguish between making dua for the deceased (asking Allah on their behalf) and asking the deceased directly for intercession. The first is encouraged; the second is a contested area where scholars differ. If uncertain, direct all supplication to Allah alone, asking Him to have mercy on those who have passed.
Is it too late to make dua for someone who died years ago? No. There is no time limit. Many Muslims make dua for deceased relatives decades or generations later. The connection of dua does not have an expiry date.
Do you feel your duas are unanswered?
Have you read the dua properly? Learn authentic duas, understand their meanings, and call upon Allah with greater confidence through DeenUp.
Take the Dua Quiz
Frequently Asked Questions
What is the dua for someone who has passed away in Islam?
The primary dua for the deceased is from the Janazah prayer: Allahumma ighfir lahu warhamhu wa afihi wa'fu anhu — O Allah, forgive him, have mercy on him, grant him safety, and pardon him (Sahih Muslim 963). Adjust to laha for a woman. This is the Prophet's authenticated formula for praying over the deceased.
Can I make dua for someone who has passed away?
Yes. Making dua for the deceased is permitted and encouraged. The Prophet said: 'When a person dies, all their deeds end except three — ongoing charity, beneficial knowledge, or a righteous child who prays for them' (Sahih Muslim 1631). Your supplications continue to reach and benefit the deceased after death.
Does dua reach the deceased in Islam?
Yes. Scholarly consensus holds that dua for the deceased reaches them and brings them benefit. The evidence includes the established practice of Janazah prayer, the hadith on three continuing deeds (Sahih Muslim 1631), and multiple narrations of the Prophet praying for those who had passed before him.
What should I say when I hear that someone has died?
Upon hearing of a death, say Inna lillahi wa inna ilayhi raji'un — Verily, we belong to Allah, and to Him we shall return (Surah Al-Baqarah, 2:156). The Quran continues that those who respond to loss with this phrase and with patience receive blessings and mercy from their Lord.
How long should I continue making dua for the deceased?
There is no fixed time limit. Scholars encourage including deceased family and community members in your regular duas indefinitely. The Prophet regularly visited graves and prayed for believers there. Many Muslims make dua for the deceased after every salah — an accessible, sustainable practice.
What is the best sadaqah to give for someone who passed away?
Any sadaqah given with the intention that its reward goes to the deceased is valid and reaches them, according to the majority of scholars. The Prophet confirmed this when asked about sadaqah given on behalf of a deceased mother (Sahih al-Bukhari 2756). Feeding the poor, paying off debts, and giving to charity all count.
Is it permissible to visit the grave and make dua there?
Yes. The Prophet visited graves and greeted the deceased, and he taught his companions the dua for visiting: Peace be upon you, O inhabitants of the graves among the believers and Muslims (Sahih Muslim 975). Visiting graves and making dua is an established sunnah, not a prohibited innovation.