What should someone do if they are unsure whether they made one or two prostrations?
Short answer
If the doubt occurs during the prayer, the person should build on certainty, perform the second prostration, and then perform sujud al-sahw. A passing doubt that arises only after the prayer has ended should be ignored.
Evidence and explanation
The source distinguishes between doubt during the prayer and doubt after it, and instructs the worshipper to build on certainty when the doubt occurs during the prayer.
Scholar referenced
This editorial summary is based on the original source linked below and is not presented as a verbatim quotation from the scholar.
From the text of the answer (Arabic, with an English translation)
Original answer — Shaykh ‘Abd al-‘Aziz ibn Baz
حكم من شك في عدد السجدات — فتوى ١٤٢٩٢- Question
«هذا السائل يقول: رجل شك في صلاته -أي: في إحدى الركعات- فلا يدري هل سجد سجدتين أم سجدة واحدة؛ ماذا يلزمه هل يسجد للسهو؟ وأين يكون سجود السهو في هذه الحالة -قبل التسليم أم بعده-؟ وبماذا تنصحون من كان كثير الشكوك والوساوس في الصلاة؟ مأجورين.»
English translation (unreviewed): This questioner says: A man doubted in his prayer, that is in one of the rak'ahs, and does not know whether he prostrated twice or once; what is required of him, does he perform the prostration of forgetfulness? And where is the prostration of forgetfulness in this case, before the salam or after? And what do you advise for one who has many doubts and whispers in the prayer? May you be rewarded.
- From the text of the answer
«إن كان شكه بعد الصلاة، بعدما سلم وانتهى، طرأ عليه الشك، لا عمل عليه، صلاته صحيحة، والحمد لله، ولا عليه سجود سهو إذا كان شكه بعد الصلاة -إنما حصل له بعد الصلاة-، هذا لا شيء عليه. أما إن كان الشك في الصلاة، فإنه يأتي بالسجدة، يبني على اليقين، إذا شك: هل سجد سجدة أو سجدتين، يأتي بالسجدة الثانية، سواء في الركعة الأولى، أو في الثانية، أو في الثالثة، أو الرابعة، ويسجد للسهو قبل السلام، وإن سجد بعد السلام فلا بأس، لكن في مثل هذا الأفضل قبل السلام.»
English translation (unreviewed): If his doubt came after the prayer, after he had given the salam and finished, and the doubt occurred to him then, he has nothing to do; his prayer is valid, praise be to Allah, and he does not owe a prostration of forgetfulness if his doubt was after the prayer. As for doubt during the prayer, he performs the prostration, building on certainty: if he doubts whether he prostrated once or twice, he performs the second prostration, whether in the first, second, third or fourth rak'ah, and prostrates for forgetfulness before the salam; and if he prostrates after the salam there is no harm, but in such a case before the salam is better.
The Arabic excerpts matched the original page word for word by an automated check and have not had human scholarly review. The English translations are unreviewed translations made for this site; they are not an approved Shari‘ah translation. Rely on the Arabic original.
Source
Ruling on doubting the number of prostrations
Shaykh ‘Abd al-‘Aziz ibn Baz, may Allah have mercy on him