The practice
How to Pray Tahajjud: Method, Time, Dua, and Benefits
Sleep first, rise, pray two rakahs at a time, close with witr. That is the whole method. The rest of this page is why the scholars called this hour the hallmark of the righteous — the moment when sincerity is most visible because no one is watching.
By Zaman Ishtiyaq · Updated August 17, 2026
Primary sources: Sahih al-Bukhari, Sahih Muslim, Quran 17:79 and 51:17–18
13 min read
In this guide
Definition
Tahajjud (Arabic: تهجد) is the voluntary night prayer performed after sleeping, before Fajr. Allah commanded it to the Prophet ﷺ directly: "And from the night, pray tahajjud as an additional prayer for you — your Lord will raise you to a praised station" (Quran 17:79). It is distinct from the obligatory five prayers; it is called qiyam al-layl (night standing) when referring to all voluntary night prayer. Tahajjud specifically means the prayer of one who rises from sleep.
The Arabic root of tahajjud — h-j-d (ه-ج-د) — carries the meaning of struggling against sleep, of rising when the body resists. Built into the word is the idea of effort, of choosing wakefulness over rest for the sake of Allah. This is not incidental. The scholars of the Islamic tradition were precise: tahajjud earns its place at the summit of voluntary worship precisely because it costs something. It is easy to pray when everyone is watching. The night makes sincerity visible.
The Quran commands it in 17:79 and praises those who practice it in multiple places. The Prophet ﷺ prayed it without abandoning it for the rest of his life. And the classical scholars — Al-Ghazali, Ibn al-Qayyim, Ibn Rajab al-Hanbali — return to it again and again as the clearest marker of a serious inner life. This page covers what tahajjud is, how to pray it, when tahajjud time begins and ends, the dua the Prophet ﷺ said on rising, what the tradition says about its benefits, and how it connects to the practice of muhasaba al-nafs.
How to Pray Tahajjud
The method of tahajjud is straightforward; the discipline is in actually rising to perform it. The following is the established practice drawn from the Prophet's ﷺ Sunnah as recorded in Bukhari and Muslim.
Sleep, then wake
Tahajjud requires that you have slept first — even briefly. This is what distinguishes it from other forms of qiyam al-layl. Sleeping, waking, making wudu, and then praying is the sequence. The wudu performed in the still of the night, in the cold, is itself an act of worship. Ibn Rajab al-Hanbali writes in Lata'if al-Ma'arif that the physical effort of the wudu at that hour is part of what opens the heart. Reciting the duas for sleep before you lie down makes the waking half of this sequence noticeably easier — you go to sleep having already named the intention to rise.
Pray in pairs — minimum two rakahs
A man asked the Prophet ﷺ about the night prayer. He replied: "The night prayer is offered as two Rak'at followed by two Rak'at and so on and if anyone is afraid of the approaching dawn (Fajr prayer) he should pray one Rak'ah and this will be a Witr for all the Rak'at which he has prayed before." (Bukhari 990; Muslim 749a). You pray two rakahs, give salam, then pray another two rakahs if you wish. The Prophet ﷺ typically prayed eight rakahs in four pairs, though he sometimes prayed fewer. The minimum is two. Pray them slowly, with presence (khushu'). Long recitation in the night prayer is recommended — this is the time to slow down, not rush.
Close with witr
Witr (an odd number of rakahs — typically one or three) is prayed last, after all pairs of night prayer. The Prophet ﷺ said: "Make witr as your last prayer at night." (Bukhari 998). Witr carries the du'a al-qunut in the Hanbali and Shafi'i positions — a supplication in the final rakah before or after ruku'. Where it is placed, and whether it is recited all year or only in the second half of Ramadan, is one of the points on which the madhhabs differ. It is a moment of direct petition to Allah before the night's prayer closes.
Best time: the last third of the night
All night prayer is virtuous, but the final third is the most praised. The Prophet ﷺ said: "Our Lord, the Blessed, the Superior, comes every night down on the nearest Heaven to us when the last third of the night remains, saying: Is there anyone to invoke Me, so that I may respond to invocation? Is there anyone to ask Me, so that I may grant him his request? Is there anyone seeking My forgiveness, so that I may forgive him?" (Bukhari 1145). To calculate the last third: divide the hours between Maghrib and Fajr into three equal parts. The final part is the time the Prophet ﷺ described. Praying in that window, even just two rakahs, carries particular weight in the tradition.
The Tahajjud Dua
No particular dua is required for tahajjud to be valid. The prayer is the two rakahs. But there is a supplication the Prophet ﷺ said when he rose at night to pray tahajjud, narrated by Ibn Abbas (ra) and recorded in Sahih al-Bukhari. It is worth noticing what it is not: it is not a list of requests. It opens by stating what is true — about Allah, about the promise, about the meeting — and only then asks for forgiveness.
On rising for tahajjud — Sahih al-Bukhari 1120
اللَّهُمَّ لَكَ الْحَمْدُ أَنْتَ قَيِّمُ السَّمَوَاتِ وَالأَرْضِ وَمَنْ فِيهِنَّ وَلَكَ الْحَمْدُ، لَكَ مُلْكُ السَّمَوَاتِ وَالأَرْضِ وَمَنْ فِيهِنَّ، وَلَكَ الْحَمْدُ أَنْتَ نُورُ السَّمَوَاتِ وَالأَرْضِ، وَلَكَ الْحَمْدُ أَنْتَ الْحَقُّ، وَوَعْدُكَ الْحَقُّ، وَلِقَاؤُكَ حَقٌّ، وَقَوْلُكَ حَقٌّ، وَالْجَنَّةُ حَقٌّ، وَالنَّارُ حَقٌّ، وَالنَّبِيُّونَ حَقٌّ، وَمُحَمَّدٌ صلى الله عليه وسلم حَقٌّ، وَالسَّاعَةُ حَقٌّ، اللَّهُمَّ لَكَ أَسْلَمْتُ، وَبِكَ آمَنْتُ وَعَلَيْكَ تَوَكَّلْتُ، وَإِلَيْكَ أَنَبْتُ، وَبِكَ خَاصَمْتُ، وَإِلَيْكَ حَاكَمْتُ، فَاغْفِرْ لِي مَا قَدَّمْتُ وَمَا أَخَّرْتُ، وَمَا أَسْرَرْتُ وَمَا أَعْلَنْتُ، أَنْتَ الْمُقَدِّمُ وَأَنْتَ الْمُؤَخِّرُ، لاَ إِلَهَ إِلاَّ أَنْتَ
Allahumma laka-l-hamd, anta qayyimu-s-samawati wa-l-ardi wa man fihinn. Wa laka-l-hamd, laka mulku-s-samawati wa-l-ardi wa man fihinn. Wa laka-l-hamd, anta nuru-s-samawati wa-l-ard. Wa laka-l-hamd, anta-l-haqq, wa wa'duka-l-haqq, wa liqa'uka haqq, wa qawluka haqq, wa-l-jannatu haqq, wa-n-naru haqq, wa-n-nabiyyuna haqq, wa Muhammadun ﷺ haqq, wa-s-sa'atu haqq. Allahumma laka aslamtu, wa bika amantu, wa 'alayka tawakkaltu, wa ilayka anabtu, wa bika khasamtu, wa ilayka hakamtu, faghfir li ma qaddamtu wa ma akhkhartu, wa ma asrartu wa ma a'lantu, anta-l-muqaddimu wa anta-l-mu'akhkhir, la ilaha illa anta.
"O Allah! All the praises are for you, You are the Holder of the Heavens and the Earth, And whatever is in them. All the praises are for You; You have the possession of the Heavens and the Earth And whatever is in them. All the praises are for You; You are the Light of the Heavens and the Earth And all the praises are for You; You are the King of the Heavens and the Earth; And all the praises are for You; You are the Truth and Your Promise is the truth, And to meet You is true, Your Word is the truth And Paradise is true And Hell is true And all the Prophets are true; And Muhammad ﷺ is true, And the Day of Resurrection is true. O Allah! I surrender (my will) to You; I believe in You and depend on You. And repent to You, And with Your help I argue And I take You as a judge. Please forgive me my previous And future sins; And whatever I concealed or revealed And You are the One who make (some people) forward And (some) backward. There is none to be worshipped but you."
The narration records an alternate ending from the same chain — la ilaha ghayruk (there is no god other than You) in place of la ilaha illa anta — and one narrator adds wa la hawla wa la quwwata illa billah. Either wording is the same hadith.
Two practical notes. First, this dua belongs to the moment of rising, before or at the start of the prayer — it is not the dua of witr. That is du'a al-qunut, which has its own wording and its own disagreement between the madhhabs about placement. Second, if you have not memorised this, nothing is lost. The night is the hour for unscripted du'a: the hadith of the last third describes Allah asking who is calling, who is asking, and who is seeking forgiveness (Bukhari 1145) — three invitations, not a script. Praise first, then istighfar, then ask in your own language for what you actually need.
Benefits in the Quran and Sunnah
The Quran does not merely recommend tahajjud as a pious extra. It describes it as a distinguishing characteristic of the people of taqwa — those who take their relationship with Allah seriously. Surah al-Dhariyat gives the clearest portrait:
"They used to sleep but little of the night, and in the hours before dawn they would seek forgiveness."
Two facts in those two ayat are worth sitting with. First, sleeping little of the night is not the command — it is the description of people whose love for Allah naturally reduced their sleep. Second, they followed the night prayer with istighfar at dawn. The pattern is: night prayer, then seeking forgiveness as Fajr approaches. This is precisely the sequence that morning adhkar preserves in condensed form for those who cannot pray the full tahajjud.
Ibn Rajab al-Hanbali, in Lata'if al-Ma'arif, develops the spiritual logic of the last third at length. He writes that the convergence of physical vulnerability (the body at rest, the world quiet, the defences of ego lowered) and divine nearness (the descent of Allah's mercy in that hour) creates a unique condition for du'a and tawbah. The person who rises for tahajjud enters this window of nearness with their heart open — stripped of the armour of the day's roles and performances — and speaks to Allah directly.
A widely circulated narration puts the same idea in the Prophet's ﷺ own words: "Hold fast to Qiyam al-Lail, for it is the practice of the righteous before you, and indeed Qiyam al-Lail is a means of nearness to Allah, a means of prevention from sin, an expiation for bad deeds, and a barrier for the body against disease." It is worth being precise about this one, because it is quoted everywhere without a grade: sunnah.com carries it as Jami' at-Tirmidhi 3549 and Darussalam grades it da'if (weak). Tirmidhi himself noted that its chain does not stand. The meaning it expresses — nearness, expiation, deterrence, and lineage with the righteous — is supported by the sahih material above. The wording is not something to attribute to the Prophet ﷺ with confidence.
The Psychological and Spiritual Benefits
The tradition's case for tahajjud is theological — Allah draws near in that hour — but it is also deeply attentive to human psychology. The night has properties that the day cannot replicate.
The first is quiet. The world does not ask anything of you at 3 a.m. There are no notifications, no demands, no audiences. The prayer you perform in that hour is for no one except Allah — and both you and Allah know it. Ibn al-Qayyim writes in Madarij al-Salikin that ikhlas (sincerity) is easiest in the acts that no one witnesses. The daytime prayer is observed; the night prayer is invisible. That invisibility is part of its value.
The second is vulnerability. Sleep is the hour when defences drop. The person who rises from sleep to pray has not had time to construct the day's persona — the professional self, the social self, the competent self. They come to Allah tired, undressed, unguarded. The scholars consistently describe this state as ideal for du'a: the heart is softened by fatigue and the absence of distraction in a way that the busy afternoon cannot produce.
The third is the neurological reset that prayer provides at the boundary between night and day. Psychologists who study sleep architecture note that waking in the early hours — what some traditions call the "second sleep" — produces a state of unusual mental clarity. The tradition located something real when it pointed to the pre-Fajr hours as the time for seeking forgiveness and making du'a. The evening adhkar structure the entry into this hour; tahajjud is the prayer that inhabits it.
Tahajjud and Muhasaba: The Natural Connection
Ibn al-Qayyim makes a point that practice confirms: "The self-accounting is best done at night, when the day is complete and the soul is quieted from the noise of its involvements." (Madarij al-Salikin, vol. 1, station of muhasaba). The night prayer and the practice of muhasaba al-nafs are not separate practices that happen to share a time slot. They belong together structurally — each enables the other.
Consider the sequence that the tradition naturally produces:
Pray first
Rise for tahajjud and begin with prayer. The prayer itself softens the heart and orients it toward Allah. You are not reviewing your failures in the abstract — you are doing so in the presence of Allah, which changes the tone entirely. The du'a within and after the prayer names your needs and your shortfalls directly.
Then reflect
After the prayer, while the heart is open and the night is still, review the day. The classical muhasaba three-step — review, acknowledge through tawbah, resolve — fits naturally into the quiet after tahajjud. This is the moment Ibn al-Qayyim describes: the day is complete, the soul is quieted, and the accounting can be honest.
Then sleep
Close the reflection with a named intention for tomorrow and sleep. The night ends with clarity rather than the unresolved accumulation that often accompanies sleep after a busy evening. Umar ibn al-Khattab (ra) said: 'Hold your souls to account before they are held to account.' The night prayer is the natural hour for that holding.
The connection to Laylatul Qadr is worth noting here: the Night of Power, which the Quran describes as better than a thousand months, is sought precisely through this combination of night prayer and sincere du'a. The person who has built a regular tahajjud habit has already established the practice that makes Laylatul Qadr possible to inhabit rather than scramble toward once a year.
How to Build the Tahajjud Habit
The Prophet ﷺ warned against promising yourself more than you can sustain: "Do good deeds properly, sincerely and moderately and know that your deeds will not make you enter Paradise, and that the most beloved deed to Allah is the most regular and constant even if it were little." (Bukhari 6464). The goal is not to begin with eight rakahs. The goal is to begin with two rakahs, consistently, until the habit has taken root. Here is a practical sequence.
Start with two rakahs
Two rakahs is the Sunnah minimum and a complete tahajjud. If this is all you can manage for the first weeks, it is enough. Pray them slowly, with a surah you know well enough to recite with presence rather than rushing through from memory. The quality of two rakahs with khushu' exceeds the quantity of eight rakahs prayed hastily.
Set an alarm 30 minutes before Fajr
The last third of the night is the most virtuous time, and the thirty minutes before Fajr fall within it. Setting a single alarm at that point is easier than calculating the exact start of the last third each night. As the habit stabilises, you may find you begin waking before the alarm — the scholars describe this as a sign that the practice has become part of the soul's rhythm. Form the niyyah for tahajjud before you sleep rather than leaving the decision to the version of you that the alarm wakes.
Combine with muhasaba journaling after the prayer
The five minutes after tahajjud, before Fajr, are the ideal slot for a brief written muhasaba. Name one shortfall from the day, make tawbah for it, name one intention for tomorrow. The combination of the prayer that opens the heart and the written reflection that names what the heart sees produces something neither practice achieves alone: honesty in the presence of Allah, carried forward as a specific resolve. The Muhasaba app structures exactly this sequence.
Protect the practice from shame spirals
You will miss nights. The tradition is clear: missing a night is not failure — it is human. What matters is returning the next night without treating the gap as evidence of worthlessness. Ibn al-Qayyim writes that the shaytan's most effective strategy with people who begin night prayer is to make one missed night feel catastrophic enough to abandon the practice entirely. The antidote is the same counsel the Prophet ﷺ gave: consistency over quantity. Two rakahs every night is better than twenty rakahs one night and nothing for the next month.
Frequently Asked Questions
What is the minimum for tahajjud?
The minimum is two rakahs. Asked about the night prayer, the Prophet ﷺ replied: "The night prayer is offered as two Rakat followed by two Rakat and so on and if anyone is afraid of the approaching dawn (Fajr prayer) he should pray one Rakah and this will be a Witr for all the Rakat which he has prayed before" (Bukhari 990; Muslim 749a). Two rakahs, prayed after sleeping and before Fajr, is a complete tahajjud. You may pray more in pairs — up to eight rakahs is the established Sunnah — and close with witr. But two rakahs, done consistently and with presence, is enough.
Can you pray tahajjud without sleeping first?
The word tahajjud specifically means the prayer of one who rises from sleep. A voluntary night prayer performed without sleeping first is technically qiyam al-layl rather than tahajjud, though both are virtuous. If you struggle to sleep before tahajjud, even a brief rest — twenty or thirty minutes — before the prayer preserves the meaning of the act. Ibn Qudamah notes that the effort of rising against sleep is part of what makes tahajjud distinctively beloved.
Is tahajjud the same as qiyam al-layl?
Qiyam al-layl is the broader term for all voluntary night prayer between Isha and Fajr, including Tarawih in Ramadan. Tahajjud is the subset that follows sleep. Every tahajjud is qiyam al-layl, but not all qiyam al-layl is tahajjud. The Quran uses tahajjud in 17:79, which the scholars interpret as pointing to its specific meaning: the prayer of one who struggles against sleep.
What time does tahajjud start and end?
Tahajjud begins after Isha prayer (once you have slept) and ends when Fajr begins. The best time is the last third of the night — calculated by dividing the period from Maghrib to Fajr into three equal parts. The Prophet ﷺ said that Allah "comes every night down on the nearest Heaven to us when the last third of the night remains" (Bukhari 1145). Practically, setting an alarm 30 minutes before Fajr puts you comfortably within this window.
Can you pray tahajjud every night?
Yes, and the Prophet ﷺ encouraged it by his own example — Aisha (ra) reported that he never exceeded eleven rakahs, in Ramadan or in any other month (Bukhari 1147). The key advice from the Sunnah is not to take on more than you can sustain: 'the most beloved deed to Allah is the most regular and constant even if it were little' (Bukhari 6464). Two rakahs every night is a better practice than eight rakahs occasionally.
Reflect after tahajjud
Write your tahajjud reflection in the Muhasaba app — free on iOS.
The Muhasaba app guides your post-tahajjud self-accounting through the classical three-step practice — review, tawbah, and resolve — in the quiet minutes before Fajr. Free on iOS.
Download on the App StoreNew to muhasaba? Learn what muhasaba al-nafs means →
Looking for adhkar to pair with tahajjud? See the morning adhkar guide →
