Quick facts about sajda al-sahw:
• Meaning: two prostrations to make up for a mistake in salah
• When: forgot a wajib, added something extra, or doubt the rakat count
• How: exactly like normal sujood, two of them
• Timing: before or after salam, depending on the school
• Basis: Sahih Muslim 571, Sahih al-Bukhari 1227, Sunan Abi Dawud 1036
Sajda al-sahw (Arabic: sajdat al-sahw) is the prostration of forgetfulness. Two extra prostrations performed when the worshiper makes a specific mistake in salah. It is not a punishment. It is not even an apology. The Prophet ﷺ called it a way to "spite the devil" (Muslim 571), since Shaytan's only role in this case was to make you forget. The believer corrects the lapse and continues. Calmly, quietly, without restarting the prayer.
One thing first: if you forget a sunnah (like a specific surah you usually recite, or saying "Allahu Akbar" between movements), there is no sajda al-sahw. The prayer is complete. Sajda al-sahw is for the three specific cases below, nothing else. FivePrayer can help you stay focused for the prayer itself, so the moments where forgetfulness creeps in get rarer over time. Free, no ads.
What is sajda al-sahw?
Sahw (Arabic: sahw) means forgetfulness, distraction, or absent-mindedness. Sajda al-sahw is the two prostrations the worshiper performs to repair a specific lapse during salah. The repair is itself a form of worship. It is not embarrassment dressed up as ritual. It is the Prophet's ﷺ way of saying: forgetting is human, and the prayer has a built-in mechanism for it.
The clearest single hadith comes from Ibn Mas'ud (RA):
The Prophet ﷺ prayed Dhuhr with five rakat. He was asked, "Has the prayer been lengthened?" He said, "What is that?" They said, "You prayed five." So he turned his feet, faced the qibla, and made two prostrations, then gave salam. Then he said: "I am only a human being. I forget as you forget. So when one of you forgets, let him perform two prostrations."
, Sahih Muslim 572 (a variant of 571)
That single account contains everything. The Prophet ﷺ himself forgot. He did not start the prayer over. He performed two prostrations and gave salam. The prayer was complete.
When sajda al-sahw is required: three cases
The classical fiqh manuals consolidate sajda al-sahw into three triggers. Knowing these three is enough for the vast majority of cases you will encounter.
Case 1: Forgetting a wajib
A wajib is a required act of the prayer that, if left out, requires repair but does not invalidate the prayer outright. The classic example: the first tashahhud. If you stand up for the third rakat in a four-rakat prayer without sitting for the first tashahhud, and you do not return (Hanafi: if you have fully stood up, do not sit back down), you owe sajda al-sahw at the end.
Other wajib acts that, if forgotten, call for sajda al-sahw:
- The first tashahhud (sitting after the second rakat in 3 or 4 rakat prayers).
- Reciting Al-Fatihah audibly in Maghrib, Isha, Fajr, or quietly in Dhuhr, Asr (specifically if you swapped them by mistake).
- Saying "Sami Allahu liman hamidah" or "Rabbana wa lakal hamd" (according to the schools that classify these as wajib).
- The Qunut in Witr (Hanafi).
Case 2: Adding something extra
If you add a rakat, an extra ruku, an extra sajda, or any other action that is not part of the prayer, but you did not invalidate the prayer by speaking or eating, you owe sajda al-sahw.
This is the case of Ibn Mas'ud above. The Prophet ﷺ prayed five rakat for Dhuhr. He performed two prostrations after salam and the prayer was complete. Five rakat in a four-rakat prayer would normally be invalid, but the two sujood repair the addition because the worshiper did not intend it.
Case 3: Doubt in the count
The most common case. You finish a rakat and cannot remember if it was the second or the third. You sit and you are not sure if you owe one more rakat or two. The rule the Prophet ﷺ taught:
If one of you is in doubt in his prayer and does not know how much he has prayed, three or four, let him cast aside doubt and build on what he is certain of. Then let him perform two prostrations before he gives salam.
, Sahih Muslim 571
This is the rule of bina ala l-yaqin, which the next section explains in detail.
Bina ala l-yaqin: the technical rule for doubt
The fuqaha encapsulate the rule of doubt in one Arabic phrase: al-bina ala l-yaqin, "building on certainty." When you doubt how many rakat you have prayed, you take the lower count as certain. The higher count is doubtful. You build the prayer on what you know for sure.
The practical translation:
- If you are unsure whether you prayed 2 or 3 rakat, treat it as 2 and pray a third.
- If you are unsure whether you prayed 3 or 4, treat it as 3 and pray a fourth.
- If you are unsure whether you prayed 1 or 2, treat it as 1 and pray a second.
Then, before giving salam (Hanafi: after salam), perform sajda al-sahw. The two prostrations cover any error caused by the doubt itself, whether you accidentally prayed one rakat too many or were correct in your second guess.
A subtle case the Hanafi school adds: if doubt happens to a worshiper for the first time, they should redo the prayer entirely (since they are not used to it and probably truly forgot). If doubt is a recurring problem, they apply bina ala l-yaqin and the sajda. This makes the ruling kinder to people who get frequent waswasa (intrusive thoughts) during prayer. The Prophet's ﷺ guidance is intended to free, not to bind further.
Before or after salam? The four schools
The hadith corpus contains examples of both: cases where the Prophet ﷺ performed sajda al-sahw before salam (Sahih Muslim 571, Ibn Mas'ud) and cases where he performed it after (Sahih al-Bukhari 482, Dhul-Yadayn). The schools resolved the apparent variation differently.
| School | Default timing | Salam |
|---|---|---|
| Hanafi | Always after salam | One salam to the right only, then two sujood, tashahhud, then full salam to both sides |
| Maliki | Before salam if for omission; after salam if for addition | Two salams as usual; if after, complete salam first then two sujood then tashahhud and salam again |
| Shafi'i | Always before salam, after final tashahhud | Tashahhud, two sujood, sit, salam |
| Hanbali | Usually before salam; after if extra rakat added or after salam in a specific hadith case | Similar to Maliki distinction in practice |
All four positions are textually grounded. The differences come from how each school weighs the hadiths and whether they treat the practices as alternatives or as different scenarios. If you follow one school in your wider practice, follow that school here too. There is no merit in mixing.
How to perform sajda al-sahw
The mechanics are simple. Two prostrations, exactly like the prostrations in your normal salah.
If you do it before salam (Shafi'i, Hanbali default, Maliki for omission):
- Complete the prayer up to the final tashahhud and salawat al-Ibrahimiyyah.
- Before turning your head to give salam, say "Allahu Akbar" and go into sujood.
- In sujood: say Subhana Rabbiyal A'la three times (or more).
- Sit up briefly with takbir, then the second sujood with the same dhikr.
- Sit up, give salam to the right and the left.
If you do it after salam (Hanafi default, Maliki for addition):
- Complete the prayer, including final tashahhud and salam (Hanafi: only one salam to the right).
- Say "Allahu Akbar" and go into sujood.
- In sujood: say Subhana Rabbiyal A'la three times.
- Sit up briefly with takbir, then second sujood with the same dhikr.
- Sit, recite tashahhud (most schools), then give salam to both sides.
There is no special du'a uniquely associated with sajda al-sahw. The standard prostration dhikr is all that is required. Some scholars recommend adding Subhana man la yanamu wa la yas-hu ("Glory be to the One who neither sleeps nor forgets"), but this is not from authenticated hadith and is not required.
What does not require sajda al-sahw
An important rule: forgetting a sunnah does not call for sajda al-sahw. The prayer is fully valid, and adding the two sujood for a missed sunnah would itself be an unauthorized addition. The following do not require it:
- Forgetting du'a al-istiftah (the opening supplication).
- Forgetting to recite a surah after Al-Fatihah in a rakat where surah is sunnah.
- Forgetting to say "Amin" after Al-Fatihah.
- Forgetting the dhikr in ruku or sujood (the dhikr itself is wajib in Hanafi but the action of bowing and prostrating is what is fard).
- Forgetting to raise the hands at takbir.
- Forgetting to look at the place of sujood, or other adab.
The Hanafi school is slightly different: it requires sajda al-sahw for missing certain wajibs that other schools classify as sunnah. If you follow Hanafi practice and you forgot the first tashahhud or the Qunut in Witr, perform sajda al-sahw. If you follow Shafi'i and forgot the same things, the rules differ slightly.
If you realized after salam
The classic case is the hadith of Dhul-Yadayn (Sahih al-Bukhari 482, Sahih Muslim 573). The Prophet ﷺ prayed Dhuhr but only completed two rakat before giving salam. A Companion, Dhul-Yadayn, asked him: "Was the prayer shortened, or did you forget?" The Prophet ﷺ asked others present, they confirmed, and he stood up, completed the remaining two rakat, gave salam, then performed two sujood and gave salam again.
From this we learn:
- Speaking briefly outside the prayer (Dhul-Yadayn's question) did not invalidate the prayer when done in genuine forgetfulness of having ended it.
- The missing rakat were completed, not the whole prayer redone.
- Two sujood followed at the end, with another salam.
For your own case: if a short time has passed (you have not left the prayer state mentally, not walked far, not engaged in unrelated activity), return, complete the missing portion, and perform sajda al-sahw. If a long time has passed, the practical position of the majority is that the prayer is broken and must be repeated. The Hanafi school is stricter about this and tends to require repetition more often.
What if I forgot something I should have done, but only remembered hours later?
If hours have passed, the prayer is over. There is no value in performing sajda al-sahw at that point. If the omission was a wajib (in Hanafi) or a pillar (rukn) of the prayer in any school, the prayer must be repeated. If it was a sunnah, the prayer was already valid and there is nothing to repair.
FAQ
What is the dhikr in sajda al-sahw?
The same as any sujood: Subhana Rabbiyal A'la ("Glory be to my Lord the Most High"), three times. No special phrase is required.
I forgot the first tashahhud and only realized while reciting in the third rakat. What do I do?
Do not return. Complete the prayer and perform sajda al-sahw at the end. Returning after you have started the next rakat would itself be an error. The Prophet ﷺ taught: "If a man stands up after the two rakat, before he sits, let him continue if he has stood fully, and let him prostrate two prostrations" (Abu Dawud 1036).
I doubt whether I prayed 3 or 4 rakat. What do I do?
Apply bina ala l-yaqin. Take 3 as certain. Pray a fourth rakat. Before salam (or after, depending on your school), perform sajda al-sahw.
Can I perform sajda al-sahw if I just feel uneasy that I might have made a mistake?
No. Sajda al-sahw is for actual identifiable mistakes (forgetting a wajib, adding extra, or genuine doubt about the count). Vague uneasiness is from Shaytan and should be ignored. Do not invent a reason to add two prostrations.
Does sajda al-sahw replace a missed rakat?
No. If you missed a full rakat, you must pray that rakat. Sajda al-sahw repairs the lapse around it, but it does not substitute for a missing pillar.
What if the imam makes a mistake during congregational prayer?
If the imam performs sajda al-sahw, the followers do too. The followers do not initiate sajda al-sahw on their own behalf during a congregation; their connection to the imam covers their own minor lapses. If the imam does not perform it but should have, the followers also do not (their job is to follow the imam in the prayer's structure).
FivePrayer: keep the prayer at the front of your day.
Accurate prayer times for your city, the adhan when it matters, and a gentle lock that helps you actually pray. Free on iOS, Android, and Chrome. The fewer the distractions before salah, the less the mind wanders during it.