Quick answer: Sahih al-Bukhari and Sahih Muslim report words the Prophet ﷺ used in distress, worry and loss, and the Quran records what earlier prophets said in hardship. This article quotes 7 of these passages, explains each in plain English and says when it is said. Du’a (supplication) is spiritual support, not a medical treatment, and anyone living with ongoing anxiety or low mood is encouraged to speak to a doctor as well.
When distress comes: the words in Bukhari
Ibn Abbas (may Allah be pleased with him) reported that the Prophet ﷺ used to invoke Allah at the time of distress. Sahih al-Bukhari lists it under a chapter on invoking Allah at a time of distress, and the same Companion’s report appears with a slightly different closing line in hadith 6346.
لاَ إِلَهَ إِلاَّ اللَّهُ الْعَظِيمُ الْحَلِيمُ، لاَ إِلَهَ إِلاَّ اللَّهُ رَبُّ السَّمَوَاتِ وَالأَرْضِ، رَبُّ الْعَرْشِ الْعَظِيمِ
Narrated Ibn `Abbas:The Prophet (ﷺ) used to invoke Allah at the time of distress, saying, "La ilaha illal-lahu Al-`Azim, al- Halim, La ilaha illal-lahu Rabbu-s-samawati wal-ard wa Rabbu-l-arsh il-azim
In plain English, the words say that there is no god but Allah, the Great (al-Azim) and the Forbearing (al-Halim), and that He is Lord of the heavens, the earth and the Mighty Throne. The wording is entirely praise, with no request in it. A person in distress begins by remembering who Allah is.
The report says he “used to” say this, which describes a habit. It gives no number of repetitions and no set time beyond the moment of distress. IslamOnline’s fiqh section notes that both al-Bukhari and Muslim reported it in their Sahihs.
Seeking refuge from worry and grief
Anas ibn Malik (may Allah be pleased with him) described a short request for protection that the Prophet ﷺ used to make. Sahih al-Bukhari 6369 lists what he sought refuge from: worry and grief, incapacity and laziness, cowardice and miserliness, heavy debt and being overpowered by other men.
اللَّهُمَّ إِنِّي أَعُوذُ بِكَ مِنَ الْهَمِّ وَالْحَزَنِ، وَالْعَجْزِ وَالْكَسَلِ، وَالْجُبْنِ وَالْبُخْلِ، وَضَلَعِ الدَّيْنِ، وَغَلَبَةِ الرِّجَالِ
Narrated Anas bin Malik:The Prophet (ﷺ) used to say, "O Allah! I seek refuge with You from worry and grief, from incapacity and laziness, from cowardice and miserliness, from being heavily in debt and from being overpowered by (other) men." (See Hadith No)
The eight items fall into two groups. Worry and grief are states of the heart, and incapacity, laziness, cowardice and miserliness are weaknesses of character. Debt and the domination of others are pressures from outside. Bukhari places the report in a chapter on seeking refuge with Allah from cowardice and laziness.
Like the first report, it says he “used to” say it. No fixed hour or count is given in the text, so how often a person makes it is left open here.
At a calamity: the Quran and Muslim
The Quran speaks about trials and about those who respond to them with patience. The verses below are the source of the phrase Muslims say when they hear of a death or a loss, known as istirja’.
وَلَنَبْلُوَنَّكُم بِشَىْءٍۢ مِّنَ ٱلْخَوْفِ وَٱلْجُوعِ وَنَقْصٍۢ مِّنَ ٱلْأَمْوَٰلِ وَٱلْأَنفُسِ وَٱلثَّمَرَٰتِ ۗ وَبَشِّرِ ٱلصَّٰبِرِينَ ﴿155﴾ ٱلَّذِينَ إِذَآ أَصَٰبَتْهُم مُّصِيبَةٌۭ قَالُوٓا۟ إِنَّا لِلَّهِ وَإِنَّآ إِلَيْهِ رَٰجِعُونَ ﴿156﴾ أُو۟لَٰٓئِكَ عَلَيْهِمْ صَلَوَٰتٌۭ مِّن رَّبِّهِمْ وَرَحْمَةٌۭ ۖ وَأُو۟لَٰٓئِكَ هُمُ ٱلْمُهْتَدُونَ ﴿157﴾
[155] And We will surely test you with something of fear and hunger and a loss of wealth and lives and fruits, but give good tidings to the patient, [156] Who, when disaster strikes them, say, "Indeed we belong to Allah, and indeed to Him we will return." [157] Those are the ones upon whom are blessings from their Lord and mercy. And it is those who are the [rightly] guided.
Sahih Muslim adds a fuller form. Umm Salamah (may Allah be pleased with her) heard the Prophet ﷺ teach that a person struck by a calamity says the Quranic phrase and then asks Allah for reward and something better in exchange. According to IslamQA’s entry on Umm Salamah, when her husband Abu Salamah (may Allah be pleased with him) died, she said what she had been taught, and Allah gave her the Messenger of Allah ﷺ as a husband.
مَا مِنْ مُسْلِمٍ تُصِيبُهُ مُصِيبَةٌ فَيَقُولُ مَا أَمَرَهُ اللَّهُ إِنَّا لِلَّهِ وَإِنَّا إِلَيْهِ رَاجِعُونَ اللَّهُمَّ أْجُرْنِي فِي مُصِيبَتِي وَأَخْلِفْ لِي خَيْرًا مِنْهَا . إِلاَّ أَخْلَفَ اللَّهُ لَهُ خَيْرًا مِنْهَا " . قَالَتْ فَلَمَّا مَاتَ أَبُو سَلَمَةَ قُلْتُ أَىُّ الْمُسْلِمِينَ خَيْرٌ مِنْ أَبِي سَلَمَةَ أَوَّلُ بَيْتٍ هَاجَرَ إِلَى رَسُولِ اللَّهِ صلى الله عليه وسلم . ثُمَّ إِنِّي قُلْتُهَا فَأَخْلَفَ اللَّهُ لِي رَسُولَ اللَّهِ صلى الله عليه وسلم . قَالَتْ أَرْسَلَ إِلَىَّ رَسُولُ اللَّهِ صلى الله عليه وسلم حَاطِبَ بْنَ أَبِي بَلْتَعَةَ يَخْطُبُنِي لَهُ فَقُلْتُ إِنَّ لِي بِنْتًا وَأَنَا غَيُورٌ . فَقَالَ " أَمَّا ابْنَتُهَا فَنَدْعُو اللَّهَ أَنْ يُغْنِيَهَا عَنْهَا وَأَدْعُو اللَّهَ أَنْ يَذْهَبَ بِالْغَيْرَةِ
Umm Salama reported Allah's Messenger (ﷺ) as saying:If any Muslim who suffers some calamity says, what Allah has commanded him," We belong to Allah and to Him shall we return; O Allah, reward me for my affliction and give me something better than it in exchange for it," Allah will give him something better than it in exchange. When Abu Salama died she said: What Muslim is better than Abu Salama whose family was the first to emigrate to the Messenger of Allah (ﷺ). I then said the words, and Allah gave me God's Messenger (ﷺ) in exchange. She said: The Messenger of Allah (ﷺ) sent Hatib b. Abu Balta'a to deliver me the message of marriage with him. I said to him: I have a daughter (as my dependant) and I am of jealous temperament. He (the Holy Prophet) said: So far as her daughter is concerned, we would supplicate Allah, that He may free her (of her responsibility) and I would also supplicate Allah to do away with (her) jealous (temperament)
The wording speaks of a calamity in general. It is said when the loss happens or when the news arrives, and the report gives no count. The request is for reward in the present pain and for a replacement that only Allah can provide.
The words of Yunus and Yaqub
The Quran preserves two short statements from prophets in hardship. The first belongs to Yunus (peace be upon him), called Dhun-Nun, “the man of the fish”, who called out from the darkness.
وَذَا ٱلنُّونِ إِذ ذَّهَبَ مُغَٰضِبًۭا فَظَنَّ أَن لَّن نَّقْدِرَ عَلَيْهِ فَنَادَىٰ فِى ٱلظُّلُمَٰتِ أَن لَّآ إِلَٰهَ إِلَّآ أَنتَ سُبْحَٰنَكَ إِنِّى كُنتُ مِنَ ٱلظَّٰلِمِينَ
And [mention] the man of the fish, when he went off in anger and thought that We would not decree [anything] upon him. And he called out within the darknesses, "There is no deity except You; exalted are You. Indeed, I have been of the wrongdoers."
The statement has three movements: Allah alone is God, Allah is far above any fault, and the speaker owns his own shortcoming. It is the words of someone who feels trapped and turns to Allah first. A hadith about this supplication is reported in another collection, so it is not quoted here.
The second belongs to Yaqub (peace be upon him), grieving for his son Yusuf.
قَالَ إِنَّمَآ أَشْكُوا۟ بَثِّى وَحُزْنِىٓ إِلَى ٱللَّهِ وَأَعْلَمُ مِنَ ٱللَّهِ مَا لَا تَعْلَمُونَ
He said, "I only complain of my suffering and my grief to Allah, and I know from Allah that which you do not know.
The verse shows a believer taking sorrow to Allah, not hiding it. Yaqub says plainly that he is in pain and that his complaint is made to Allah alone. Neither verse sets a number or a time, so both are said whenever the situation calls for them.
Tears and grief: what Bukhari reports
Hardship also brings tears, and Sahih al-Bukhari records how the Prophet ﷺ behaved at his son’s deathbed. Anas reported that they went with Allah’s Messenger to the blacksmith Abu Saif, husband of the wet-nurse of Ibrahim. When the Prophet’s ﷺ eyes filled, Abd al-Rahman ibn Awf (may Allah be pleased with him) said, “Even you are weeping!” The Prophet ﷺ answered that this is mercy.
يَا ابْنَ عَوْفٍ إِنَّهَا رَحْمَةٌ ". ثُمَّ أَتْبَعَهَا بِأُخْرَى فَقَالَ صلى الله عليه وسلم " إِنَّ الْعَيْنَ تَدْمَعُ، وَالْقَلْبَ يَحْزَنُ، وَلاَ نَقُولُ إِلاَّ مَا يَرْضَى رَبُّنَا، وَإِنَّا بِفِرَاقِكَ يَا إِبْرَاهِيمُ لَمَحْزُونُونَ ". رَوَاهُ مُوسَى عَنْ سُلَيْمَانَ بْنِ الْمُغِيرَةِ عَنْ ثَابِتٍ عَنْ أَنَسٍ ـ رضى الله عنه ـ عَنِ النَّبِيِّ صلى الله عليه وسلم.
Narrated Anas bin Malik:We went with Allah's Messenger (ﷺ) to the blacksmith Abu Saif, and he was the husband of the wet-nurse of Ibrahim (the son of the Prophet). Allah's Messenger (ﷺ) took Ibrahim and kissed him and smelled him and later we entered Abu Saif's house and at that time Ibrahim was in his last breaths, and the eyes of Allah's Messenger (ﷺ) started shedding tears. `Abdur Rahman bin `Auf said, "O Allah's Apostle, even you are weeping!" He said, "O Ibn `Auf, this is mercy." Then he wept more and said, "The eyes are shedding tears and the heart is grieved, and we will not say except what pleases our Lord, O Ibrahim ! Indeed we are grieved by your separation
The report separates feeling from speech. The eyes may weep and the heart may ache, and the tongue says only what pleases the Lord. It is not a formal du’a with a set time, but the sentence gives a pattern for what to say at a funeral or at the news of a death.
Sahih Muslim also reports a saying of the Prophet ﷺ, narrated by Suhayb, about adversity. As given in Riyad as-Salihin 27, if prosperity attends the believer he thanks Allah, and if adversity befalls him he endures it patiently, and that is better for him. It is a reminder that patience and these words go together.
The words side by side
| Situation | When it is said | How often | Source |
|---|---|---|---|
| Distress | At a time of distress | He “used to” say it; no count reported | Sahih al-Bukhari 6345 (another wording in 6346) |
| Worry, grief, debt | No fixed time reported | He “used to” say it; no count reported | Sahih al-Bukhari 6369 |
| Trial or loss (the Quranic phrase) | When afflicted by calamity | No count given | Quran 2:155-157 |
| Calamity (fuller form) | When a calamity strikes | No count reported | Sahih Muslim 918a |
| Feeling trapped and at fault | In a tight spot | No count given | Quran 21:87 (words of Yunus) |
| Taking sorrow to Allah | In grief | No count given | Quran 12:86 (words of Yaqub) |
| Tears at a death | At a bereavement | Not applicable | Sahih al-Bukhari 1303 |
What is not covered here
Other well-known words for hardship, such as a short phrase taught to Asma bint Umays (may Allah be pleased with her) and the supplication that asks Allah to make the Quran the spring of the heart, rest on collections outside Bukhari and Muslim. They are named here and not quoted.
General manners of du’a, such as facing the qiblah, praising Allah first and not rushing, are also left out because this article doesn’t reproduce a report on them. The first text above does begin with praise of Allah, which is visible in its own wording. For a personal situation such as a bereavement, a debt or long-lasting distress, a qualified local scholar can advise on what applies to the individual.
Sources
- Sunnah.com: Sahih al-Bukhari 6345, Invocations
- Sunnah.com: Sahih al-Bukhari 6346, Invocations
- Sunnah.com: Sahih al-Bukhari 6369, Invocations
- Sunnah.com: Sahih al-Bukhari 1303, Funerals
- Sunnah.com: Riyad as-Salihin 27, The Book of Miscellany
- IslamOnline Fiqh: Supplications During Frustration and Difficulty
- Islam Question and Answer: Wives of Prophet Muhammad
Header image: illustration, AI-generated.

