Speaking Deliberately
The jurists agree that speaking in prayer with words not part of it invalidates the prayer. This is based on the hadith of Zayd ibn Arqam and the hadith of Muʿawiyah ibn al-Hakam in which speech in prayer was prohibited. If done intentionally, it invalidates the prayer by consensus, as reported by Ibn al-Mundhir in al-Ijmaʿ. On speech done forgetfully or out of ignorance:
- Hanafis (Hashiyat Ibn ʿAbidin, Ibn ʿAbidin): Invalid in all cases, including forgetfulness, ignorance, coercion, mistake, or light sleep.
- Shafiʿis (Mughni al-Muhtaj, al-Khatib al-Shirbini; al-Majmuʿ Sharh al-Muhadhdhab, al-Nawawi): Does not invalidate if the person is new to Islam or lived far from scholars.
- Hanbalis (Mutalib Uli al-Nuha, Mansur al-Buhuti): Invalid if done forgetfully, under coercion, or for the prayer’s benefit, but not if from light sleep or a slip of the tongue. The stronger view, supported by Ibn ʿUthaymin in al-Sharh al-Mumtiʿ, is that ignorance or forgetfulness does not invalidate the prayer. This is based on al-Ahzab 33:5, al-Baqarah 2:286, the hadith in Sunan Ibn Majah and al-Mustadrak, and the incident of Muʿawiyah ibn al-Hakam.
Eating and Drinking Deliberately
If done intentionally in prayer, all jurists agree it invalidates. Regarding forgetfulness:
- Hanafis (Hashiyat Ibn ʿAbidin, Ibn ʿAbidin): Invalid in all cases.
- Malikis (Hashiyat al-Dusuqi, Muhammad ʿUlaysh al-Dusuqi) and Shafiʿis (Mughni al-Muhtaj, al-Khatib al-Shirbini): Does not invalidate, whether the prayer is obligatory or voluntary.
- Hanbalis (Kashshaf al-Qinaʿ, Mansur al-Buhuti): Invalid in obligatory prayer but not in voluntary; another narration allows it if the amount is little. The stronger view is the Maliki and Shafiʿi position: Little eating or drinking forgetfully does not invalidate, but large amounts do as they contradict the prayer’s form.
Ruling on Adding Extra Actions or Recitations in Prayer
If an act is of the same type as prayer acts, such as bowing or prostrating in the wrong place, then if done intentionally the prayer is invalid as it is considered playing with the prayer. If done forgetfully, the prayer is not invalidated, as shown by the hadith in Sahih al-Bukhari and Sahih Muslim in which the Prophet prayed Dhuhr as five rakʿahs and continued. On repeating al-Fatihah intentionally, the Shafiʿi madhhab has two views.
The stronger view, held by the majority and recorded by al-Nawawi in al-Majmuʿ Sharh al-Muhadhdhab, is that it does not invalidate because it is dhikr.
The other view, narrated by al-Juwayni from Abu al-Walid al-Naysaburi and mentioned in al-ʿUddah by al-Qaffal from Abu ʿAli ibn Khayran and Abu Yahya al-Balkhi, and reported from the old position by al-Shaykh Abu Hamid, is that it does invalidate.
Al-Mutawalli in al-Tatimmah and others state that repeating the final tashahhud and salat upon the Prophet intentionally also does not invalidate.
Leaving a Condition, Pillar, or Obligation
Leaving a pillar intentionally invalidates the prayer by consensus. If a pillar is left forgetfully or out of ignorance, the jurists agree it must be performed if possible. Hanafis (Hashiyat Ibn ʿAbidin, Ibn ʿAbidin; Bada’iʿ al-Sana’iʿ, al-Kasani) hold that the prayer is invalid regardless.
The majority (Malikis in Hashiyat al-Dusuqi, Shafiʿis in Sharh Rawdat al-Talibin by al-Nawawi, and Hanbalis in Kashshaf al-Qinaʿ by al-Buhuti) hold that only the rakʿah from which the pillar was missed is invalid, except for the intention and opening takbir, in which case the whole prayer must be repeated.
Ibn Qudamah in al-Mughni states that if remembered after the salam and the gap is long according to custom, the prayer is invalid, but if the gap is short, the missed pillar is completed and the prayer continued.
Doing Much Action Deliberately
Excessive movement that is not from the acts of prayer and without necessity invalidates the prayer, and the amount is determined by custom. Small actions such as carrying a child or opening a door do not harm the prayer.
This is supported by the hadith in Sahih al-Bukhari from Abu Qatadah in which the Prophet carried Umamah bint Zaynab during prayer, and the hadith in Sunan Abi Dawud from Aishah in which the Prophet walked to open the door while in prayer.
Laughing and Smiling in the Prayer
Loud laughter that produces two clear letters invalidates the prayer in all cases, whether it is little or much. Smiling does not invalidate.
Ibn al-Mundhir in al-Ijmaʿ reports consensus on laughter invalidating prayer.
This is the view of the Hanafis (Hashiyat Ibn ʿAbidin, Ibn ʿAbidin), Malikis (Hashiyat al-Dusuqi, al-Dusuqi), Hanbalis (Mutalib Uli al-Nuha, al-Buhuti), and Shafiʿis (al-Majmuʿ Sharh al-Muhadhdhab, al-Nawawi). If loud laughter occurs unintentionally and the person cannot control it, the correct view is that it does not invalidate the prayer.
Full Article
Speaking deliberately
The jurists agreed that prayer becomes invalid if one speaks during it with something not from its acts. The evidence for this is what Muslim narrated from Zayd ibn Arqam (may Allah be pleased with him) who said: “We used to speak during the prayer. A man would speak to his companion who was next to him in the prayer, until the verse was revealed: ‘And stand before Allah devoutly’ (al-Baqarah 2:238). We were then commanded to remain silent and forbidden from speaking” (Narrated by Muslim in the Book of Mosques and Places of Prayer, chapter on the prohibition of speaking in prayer and the abrogation of what was permitted, hadith no. 539).al-Bukhari 1200, 4534, Muslim 539, Abu Dawud 949, al-Tirmidhi 405).
Also, the statement of the Prophet, peace and blessings be upon him, to Muʿawiyah ibn al-Hakam al-Sulami (may Allah be pleased with him): “This prayer is not suitable for anything from the speech of people. It is only for tasbih, takbir, and the recitation of the Quran” (Sahih Muslim 537).
Prayer is invalidated by speaking if the person speaks intentionally. As for if he forgets, or his tongue slips while reciting or similar, the jurists differed in this:
-
- The Hanafis (Hashiyat Ibn ʿAbidin 1/413) did not differentiate in this matter. They said the prayer of one who speaks is invalid whether he forgot, was asleep, ignorant, mistaken, coerced, or the like.
- The Shafiʿis (Mughni al-Muhtaj 1/195–196) hold that the prayer of one who speaks forgetfully or out of ignorance of its prohibition is not invalid if his acceptance of Islam is recent or he grew up far from scholars.
- The Hanbalis (Mutalib Uli al-Nuha 1/520–538) hold that prayer becomes invalid by the speech of one who forgets, is coerced, or speaks for the benefit of the prayer and similar cases. They do not consider the prayer invalidated by the speech of one who was asleep if the sleep was light, nor by speech from a slip of the tongue, because that is beyond his control.
The correct view among these is that the prayer of one who speaks forgetfully or out of ignorance is not invalidated (al-Sharh al-Mumtiʿ 3/365). The evidence for this is the saying of Allah: “There is no blame upon you for what you do mistakenly, but only for what your hearts intend” (al-Ahzab 33:5), and His saying: “Our Lord, do not take us to task if we forget or make a mistake” (al-Baqarah 2:286), to which Allah said: “I have done so.”
Also, the previously mentioned hadith of Muʿawiyah ibn al-Hakam, when he spoke in prayer and said to the man who sneezed, “May Allah have mercy on you” (Narrated by Muslim in the Book of Mosques, chapter on the prohibition of speaking in prayer and the abrogation of what was permitted, hadith no. 539). The Prophet, peace and blessings be upon him, did not command him to repeat the prayer because he was ignorant.
This hadith is proof of the prohibition of speaking during the prayer. There is no disagreement among the scholars that if a person speaks in his prayer deliberately and knowingly, his prayer becomes invalid.
They differed over the ruling of one who is ignorant or forgetful. Some scholars held that the ignorant and forgetful are the same as the deliberate one, but the stronger view is to differentiate between them. The prayer of one who is forgetful or ignorant is not invalidated by speech, unlike the one who speaks deliberately. The evidence for this is:
The saying of the Prophet, peace and blessings be upon him: “Indeed Allah has pardoned for my Ummah mistakes, forgetfulness, and what they are compelled to do” (authentic, narrated by Ibn Majah 2045, al-Hakim 198 from Ibn Abbas, and he authenticated it according to the conditions of al-Bukhari and Muslim, and al-Dhahabi agreed. It has supporting narrations from Ibn Umar, Uqbah ibn Amir, Abu al-Darda, and Thawban).
The hadith of Muawiyah ibn al-Hakam al-Sulami, may Allah be pleased with him, who said: While I was praying with the Messenger of Allah, peace and blessings be upon him, a man among the people sneezed, so I said: May Allah have mercy on you. The people looked at me, so I said: Woe to my mother, what is wrong with you that you look at me?
They began striking their hands on their thighs, and when I saw them urging me to be silent, I kept quiet. When the Messenger of Allah, peace and blessings be upon him, finished the prayer, by my father and mother, I have never seen a teacher before him or after him better in teaching than him. By Allah, he did not scold me, hit me, or insult me. He said: “This prayer is not suitable for any of the speech of people, it is only for tasbih, takbir, and recitation of the Quran” (Muslim 537, Abu Dawud 930, al-Nasai 3/14, Ahmad 5/447).
This hadith is proof for the prohibition of speaking in prayer absolutely, whether there is a need or no need, whether for rectifying the prayer or for something else.
As for those who permitted speaking for a benefit, using as evidence the hadith of Dhu al-Yadayn (which will be mentioned in the chapters on the prostration of forgetfulness), their evidence is not sound for what they claim. However, what can be understood from the hadith of Dhu al-Yadayn is that if someone spoke thinking his prayer had ended, that does not invalidate his prayer.
It should be known that there is no authentic proof that uttering a letter or two from crying, blowing, or similar actions invalidates the prayer, because this is not considered speech. It is like spitting, and the scholars agree that spitting does not invalidate the prayer. In fact, the opposite has been reported. From Abdullah ibn Amr, may Allah be pleased with them both, that the Prophet, peace and blessings be upon him, blew during the eclipse prayer (Graded Hasan, narrated by Ahmad 2/188, Abu Dawud 1194, al-Nasai 3/57).
Translation: An Nawawi said: The views of the scholars regarding the speech of one who is praying
Speech in prayer is of three categories.
The first is that he speaks intentionally without any benefit for the prayer. In this case, his prayer becomes invalid by consensus. Ibn al-Mundhir (d. 318 AH) and others transmitted this consensus.
The evidence for it includes the previously mentioned hadith of Muʿawiyah ibn al-Hakam, the hadith of Ibn Masʿud (may Allah be pleased with him), the hadith of Jabir (may Allah be pleased with him), the hadith of Zayd ibn Arqam (may Allah be pleased with him), and other hadiths that we will mention, if Allah wills.
The second is that he speaks for the benefit of the prayer, such as if the imam stands for a fifth rakʿah and someone says, “You have prayed four,” or something similar. Our madhhab, as well as the madhhab of the majority of scholars, is that the prayer becomes invalid.
Al-Awzaʿi (d. 157 AH) said it does not become invalid, and this is also a narration from Malik (d. 179 AH) and Ahmad (d. 241 AH). The evidence for the majority is the general wording of the authentic hadiths prohibiting speech, and the saying of the Prophet, peace and blessings be upon him, “If something occurs to someone during his prayer, let the men say ‘Subhan Allah’ and let the women clap.” If speech for the sake of the prayer were permissible, it would have been easier and clearer. As for the hadith of Dhu al-Yadayn, its answer will come, if Allah wills.
The third is that he speaks out of forgetfulness and his speech is not lengthy. Our madhhab is that his prayer does not become invalid, and this is also the view of the majority of scholars, among them Ibn Masʿud (may Allah be pleased with him), Ibn Abbas (may Allah be pleased with him), Ibn al-Zubayr (may Allah be pleased with him), Anas (may Allah be pleased with him), ʿUrwah ibn al-Zubayr (d. 94 AH), Ata’ (d. 114 AH), al-Hasan al-Basri (d. 110 AH), al-Shaʿbi (d. 103 AH), Qatadah (d. 118 AH), all the hadith scholars, Malik, al-Awzaʿi, Ahmad in one narration, Ishaq, Abu Thawr, and others (may Allah have mercy on them). Al-Nakhaʿi (d. 96 AH), Hammad ibn Abi Sulayman (d. 120 AH), Abu Hanifah (d. 150 AH), and Ahmad in another narration said that the prayer becomes invalid.
Abu Hanifah agreed with us that responding to greetings does not invalidate the prayer. Those who say it becomes invalid use as proof the hadith of Ibn Masʿud (may Allah be pleased with him) who said: “We used to greet the Messenger of Allah, peace and blessings be upon him, while he was in prayer and he would return our greeting.
When we returned from the land of the Negus, I greeted him and he did not return it, so I said, ‘O Messenger of Allah, we used to greet you in prayer and you would return our greeting.’ He said, ‘Prayer occupies one.’” This was narrated by al-Bukhari and Muslim. In the narration of Abu Dawud and others, there is the addition: “Indeed Allah decrees in His affair what He wills, and He has decreed that you should not speak in prayer.”
From Jabir (may Allah be pleased with him) who said: “The Messenger of Allah, peace and blessings be upon him, sent me on an errand. I went, then returned, and I came to the Prophet, peace and blessings be upon him, and greeted him, but he did not respond. Something entered my heart which only Allah knows.
Then I greeted him again and he did not respond, and something heavier entered my heart than the first time. Then I greeted him and he said: ‘What prevented me from responding to you is that I was praying.’ He was on his mount facing other than the qiblah.” (Sunan Nasai 1190)
Al-Majmu’ Sharh al-Muhaddhab (4/16-17)

Translation: Ibn Qudamah Al Hanbali said: The speech that invalidates prayer is that which is made up of two letters. This is the view of our companions and the companions of Ash-Shafiʿi, because with two letters a word is formed, such as “ab,” “akh,” or “dam.” Likewise are verbs and particles, for no word is formed from less than two letters.
If he says “la” (no), his prayer is invalidated, because it consists of two letters: lam and alif. If he laughs and two letters become clear, his prayer is invalidated, and likewise if he laughs loudly (qahqahah) without two letters becoming clear.
This is also the view of Jabir ibn Abdullah (may Allah be pleased with him), Ata’ (d. 114 AH), Mujahid (d. 104 AH), al-Hasan (d. 110 AH), Qatadah (d. 118 AH), al-Nakhaʿi (d. 96 AH), al-Awzaʿi (d. 157 AH), al-Shafiʿi (d. 204 AH), and the scholars of opinion, and no opponent is known in this matter.
Ibn al-Mundhir (d. 318 AH) said: They have agreed that laughter invalidates the prayer, and most scholars hold that smiling does not invalidate it. Jabir ibn Abdullah (may Allah be pleased with him) narrated from the Prophet, peace and blessings be upon him, that he said: “Loud laughter invalidates the prayer but does not invalidate the wudu.” This was narrated by al-Daraqutni in his Sunan.
Al Mughni By Ibn Qudamah (2/451)
Eating and drinking deliberately
The jurists agreed that if a person eats or drinks in his prayer intentionally, his prayer becomes invalid. But they differed regarding one who eats or drinks forgetfully. The Hanafis (Hashiyat Ibn ʿAbidin 1/418) hold that his prayer becomes invalid, while the Malikis (Hashiyat al-Dusuqi 1/289) and Shafiʿis (Mughni al-Muhtaj 1/200) hold that it does not become invalid.
The Hanbalis (Kashshaf al-Qinaʿ 1/398) differentiate between types of prayer: if it is an obligatory prayer, it becomes invalid, but if it is a voluntary prayer, it does not. Another narration in the madhhab is that if the eating or drinking is little, it does not invalidate, but if it is much, it does.
The correct view is the saying of the Malikis and Shafiʿis that the prayer of one who eats or drinks forgetfully does not become invalid, whether the prayer is obligatory or voluntary.
This is due to the generality of Allah’s saying: “وَلَيْسَ عَلَيْكُمْ جُنَاحٌ فِيمَا أَخْطَأْتُم بِهِ وَلَٰكِن مَّا تَعَمَّدَتْ قُلُوبُكُمْ” “There is no blame upon you for what you do mistakenly, but only for what your hearts intend” (al-Ahzab 33:5),
and His saying: “رَبَّنَا لَا تُؤَاخِذْنَا إِن نَّسِينَا أَوْ أَخْطَأْنَا” “Our Lord, do not take us to task if we forget or make a mistake” (al-Baqarah 2:286), to which the Lord said: “I have done so.”
The saying of the Prophet, peace and blessings be upon him: “Indeed Allah has pardoned my Ummah for mistakes, forgetfulness, and what they are coerced into” (Narrated by Ibn Majah in the Book of Divorce, chapter on the divorce of the coerced and the forgetful, hadith no. 2043, authenticated by al-Albani in Sahih Sunan Ibn Majah 1/347 no. 1662).
This applies if the eating or drinking is little. As for if it is much, there is no doubt that it is impossible to happen unknowingly; for how can one eat or drink while praying and still not realise he is in prayer? If this did happen, the correct view is that it invalidates the prayer because it departs from the form of the prayer. The limit between little and much returns, in the correct view, to custom.

Ibn al-Mundhir said: “The scholars are unanimously agreed that whoever eats or drinks deliberately during an obligatory prayer must repeat it” (al-Ijma p. 8).
The same applies to voluntary prayer according to the majority, because whatever invalidates the obligatory prayer also invalidates the voluntary.

Translation: In the view of the scholars regarding eating and drinking during prayer. Ibn al-Mundhir (d. 318 AH) said: The scholars have agreed that both are forbidden, and that if a person eats or drinks during an obligatory prayer intentionally, he must repeat it.
If he does so out of forgetfulness, Ata’ (d. 114 AH) said: It does not invalidate it, and this is my view. Al-Awzaʿi (d. 157 AH) and the scholars of opinion said: It does invalidate it.
As for voluntary prayer, it is narrated from Ibn al-Zubayr (may Allah be pleased with him) and Saʿid ibn Jubayr (d. 95 AH) that they drank during voluntary prayer. Tawus (d. 106 AH) said: There is no harm in it. Ibn al-Mundhir said: This is not permissible, and perhaps those who reported this from them related an instance when they did it out of forgetfulness.
Al-Majmu’ Sharh al-Muhaddhab (4/23)
Therefore, a person should be keen to rinse his mouth and use the siwak before prayer as much as possible. Allah is the One whose help is sought.
Ruling on Adding Extra Actions or Recitations in Prayer

Translation: An Nawawi said: If a person performs in prayer an action that is not part of it, then it is examined. If it is of the same type as the acts of prayer, such as bowing or prostrating in a place where they are not due, then if he does so intentionally, his prayer becomes invalid because he is playing with the prayer.
If he does so out of forgetfulness, it does not invalidate the prayer, because the Prophet, peace and blessings be upon him, “prayed Dhuhr as five rakʿahs, so they made tasbih to him, and he completed his prayer based on what he had prayed.” If he recites al-Fatihah twice intentionally, the stated opinion is that his prayer is not invalidated, because it is a repetition of dhikr, just as if he recites the surah after al-Fatihah twice. Some of our companions said it becomes invalid because he has added a pillar to the prayer, so it is like adding an extra bowing or prostration.
This hadith was narrated by al-Bukhari and Muslim in meaning from the narration of Abdullah ibn Masʿud (may Allah be pleased with him). Our companions said: If he adds an act from the pillars of prayer intentionally, his prayer is invalidated. If it is out of forgetfulness, his prayer is not invalidated by adding one pillar, multiple pillars, one rakʿah, or more, due to the hadith, and because it is something that cannot be fully avoided. If he recites al-Fatihah twice out of forgetfulness, it does not harm his prayer.
If he does so intentionally, there are two views. The correct and stated opinion is that it does not invalidate the prayer because it does not disrupt the form of the prayer.
The second view is that it does invalidate the prayer, like repeating the bowing. This view was narrated by Al Juwayni from Abu al-Walid al-Naysaburi, one of our great early companions in fiqh, who studied under Ibn Surayj. It was also narrated by the author of al-ʿUddah from Abu Ali ibn Khayran and Abu Yahya al-Balkhi, and al-Shaykh Abu Hamid narrated it from the old position.
The correct position in the madhhab, which is the view of the majority, is that it does not invalidate the prayer. Likewise, if he repeats the final tashahhud and the salat upon the Messenger of Allah, peace and blessings be upon him, intentionally, it does not invalidate the prayer for the same reason mentioned. Al-Mutawalli and others said: If he repeats al-Fatihah, and we say that his prayer is not invalidated, it does not suffice in place of the surah after al-Fatihah.
Al-Majmu’ Sharh al-Muhaddhab (4/23-24)
Leaving A Condition, Pillar, or Obligation:
The jurists agreed that whoever leaves a pillar from the pillars of prayer intentionally, his prayer is invalid and not valid. If he leaves it out of forgetfulness or ignorance, they agreed that he must perform it if it is possible to make it up. If it is not possible to make it up, they differed:
The Hanafis (Hashiyat Ibn ʿAbidin 1/297–368; Bada’iʿ al-Sana’iʿ 1/113, 167, 168, 170) hold that his prayer is invalid. The majority (see Hashiyat al-Dusuqi 1/239, 279; Sharh Rawdat al-Talibin 1/187–188; Kashshaf al-Qinaʿ 1/385, 402) hold that only the rakʿah from which the pillar was left is invalidated, provided the pillar left is not the intention or the opening takbir, for in those two cases the prayer must be restarted because he is not considered to be praying.


Translation:
Chapter By Ibn Qudamah: What invalidates the prayer if it is left out intentionally or out of forgetfulness
Issue 212: He said, “Whoever leaves out the opening takbir, or the recitation of al-Fatihah when he is an imam or praying alone, or the bowing, or standing upright after the bowing, or the prostration, or sitting upright after the prostration, or the final tashahhud, or the salam, his prayer is invalid, whether he left it out intentionally or forgetfully.”
The summary of the matter is that what is prescribed in the prayer is of two types: obligatory and recommended. The obligatory is of two kinds: The first is that which is never dropped, whether intentionally or forgetfully.
This is what al-Khiraqi mentioned in this issue, and they are ten things: the opening takbir, the recitation of al-Fatihah for the imam and the one praying alone, standing, bowing until one is tranquil in it, standing upright from bowing until one is tranquil, prostrating until one is tranquil, sitting upright between the two prostrations until one is tranquil, the tashahhud at the end of the prayer, sitting for it, the salam, and the order of the prayer as we have previously mentioned.
These are called the pillars of the prayer and are not dropped in any circumstance, whether intentional or out of forgetfulness. There is a difference of opinion regarding the obligation of some of these, which we have already mentioned, but most of them are proven to be obligatory by what Abu Hurayrah (may Allah be pleased with him) narrated, that the Messenger of Allah, peace and blessings be upon him, entered the masjid, and a man came in and prayed, then came and greeted the Prophet, peace and blessings be upon him. The Prophet said to him, “Go back and pray, for you have not prayed.”
So he went back and prayed, then came and greeted him again, and the Prophet said, “Go back and pray, for you have not prayed.” This happened three times until the man said, “By the One Who sent you with the truth, I do not know any better, so teach me.”
The Prophet said, “When you stand for prayer, say the takbir, then recite what is easy for you from the Quran, then bow until you are tranquil in bowing, then rise until you are standing straight, then prostrate until you are tranquil in prostration, then sit until you are tranquil sitting, then prostrate until you are tranquil in prostration, then do that throughout your prayer.” This is agreed upon. Muslim added: “When you stand for prayer, perfect your wudu, then face the qiblah and say the takbir.”
This proves that these pillars mentioned here are not dropped under any circumstance, for if they were to be dropped, they would have been dropped for the Bedouin due to his ignorance of them. And the ignorant is like the forgetful.
The ruling on leaving them is that whoever leaves them intentionally, his prayer is invalid immediately. Whoever leaves something from them forgetfully and remembers it during the prayer must perform it, as will be explained later, if Allah wills. If he does not remember until after he has given the salam and a long time has passed, his prayer becomes invalid, because it is not possible to build what remains of it upon what has passed when the gap is long. If the gap is not long, then he builds upon what he has already prayed.
This was explicitly stated by Ahmad (d. 241 AH) in the narration of a group, and this is also the saying of al-Shafiʿi (d. 204 AH), and Malik (d. 179 AH) said something similar. The determination of what is a long or short gap returns to common custom.
Some of our companions said: Whenever he leaves a pillar and does not perform it until he has given the salam, his prayer is invalid. Al-Nakhaʿi (d. 96 AH) and al-Hasan (d. 110 AH) said: Whoever forgets a prostration in the prayer and remembers it while still in the prayer should perform it whenever he remembers it, and when he completes his prayer, he should perform the two prostrations of forgetfulness.
Mak’hul (d. 112 AH) and Muhammad ibn Aslam al-Tusi (d. 242 AH) said regarding the one praying who forgets a prostration or a rakʿah, that he should perform it whenever he remembers, and then perform the two prostrations of forgetfulness. Al-Awzaʿi (d. 157 AH) said about a man who forgot a prostration in Dhuhr prayer and remembered it during Asr, that he should continue his prayer, and when he finishes, he should perform it.
Our evidence that the prayer does not become invalid when the gap is short is that if someone leaves a rakʿah or more and remembers before the gap becomes long, he performs what he left and his prayer is not invalid by consensus. This is indicated by the hadith of Dhu al-Yadayn. So if he leaves a single pillar, it is even more deserving that his prayer is not invalidated, since this is less than leaving a rakʿah.
The evidence that the prayer becomes invalid with a long gap is that it breaks the continuity, so the prayer is not valid, just as if he remembered it the next day. There is no set limit in the Sharia for what is considered a long gap; rather, it is referred to custom, as is the case with other matters that have no fixed limit. This is the saying of some of Ash-Shafiʿi’s companions. Al-Khiraqi said regarding sujud al-sahw: He should perform it as long as he is still in the masjid, because it is the place of the prayer, so closeness and remoteness are measured by it. Some of al-Shafiʿi’s companions said: The long gap is the length of a rakʿah, and this is what is explicitly stated from al-Shafiʿi. Others said: It is the length of the prayer in which the pillar was forgotten. Our position is that there is no set limit for it in the Sharia, so it returns to custom, like all matters with no set limit.
Al Mugni By Ibn Qudamah (2/381-384)
Doing much action deliberately:
The prayer becomes invalid by excessive movement which is not from the type of the prayer’s acts if it is without necessity. The measure of what is excessive is by custom, which is what would make an onlooker think that he is not in prayer.
If the movement is slight, like carrying a child or opening a nearby door or similar small acts, the prayer is not invalidated by it. The evidence for this is what al-Bukhari narrated from Abu Qatadah (may Allah be pleased with him) “that the Prophet, peace and blessings be upon him, used to pray while carrying Umamah bint Zaynab bint the Messenger of Allah, peace and blessings be upon him, from Abu al-As ibn al-Rabiʿ ibn ʿAbd Shams. When he prostrated, he put her down, and when he stood, he carried her” (Narrated by al-Bukhari in the chapters on the sutrah of the one praying, chapter on carrying a small girl on the neck in prayer, hadith no. 494, and by Muslim in the Book of Mosques and Places of Prayer, chapter on the permissibility of carrying children in prayer, hadith no. 543, with the wording from al-Bukhari).
And from Aishah (may Allah be pleased with her) who said: “I came while the Messenger of Allah, peace and blessings be upon him, was praying in the house and the door was closed. He walked until he opened for me, then returned to his place”(Sunan Abu Dawud 922, Sunan at-Tirmidhi 601, Sunan an-Nasa’i 1206)

Al-Nawawi said: As for the ruling on this issue, the summary of what our companions have said is that an action which is not from the type of actions of prayer, if it is a lot, invalidates the prayer without any disagreement.
If it is a little, it does not invalidate it without any disagreement. This is the guiding principle. Then they differed in defining what is little and what is much into four views.
The first view is that little is what does not take enough time to perform an entire rakʿah, and much is what does take that amount of time. This was stated by al-Rafiʿi (d. 623 AH), but it is weak or mistaken.
The second view is that any act which does not require the use of both hands, such as lifting a turban, untying the straps of trousers, and similar, is little. What requires both hands, such as wrapping a turban, tying a waist-wrapper, or fastening trousers, is much. This was narrated by al-Rafiʿi.
The third view is that little is what an observer would not think from seeing it that the person is not in prayer, and much is what would lead him to think that he is not in prayer. This was weakened because someone who sees a person carrying a small child, or killing a snake or scorpion, and similar actions, may think he is not in prayer, yet this amount does not invalidate the prayer by agreement.
The fourth view, which is the correct and well-known one, and which the author and the majority have affirmed, is that the matter is referred back to custom. What people consider little, such as signalling in response to greetings, removing shoes, raising a turban and putting it down, wearing and removing a light garment, carrying a small child and putting him down, pushing away someone passing in front, or spitting into one’s garment, and similar actions, does not harm the prayer.
What people consider much, such as taking many consecutive steps or performing successive acts, invalidates the prayer.
Al-Majmu’ Sharh al-Muhaddhab (4/25)
Laughing and Smiling in the prayer:
If the person praying laughs audibly such that he or others can hear it, his prayer becomes invalid whether it is little or much, because it contradicts the prayer and is closer to mockery and play. This is the view of the majority of jurists from the Hanafis (Hashiyat Ibn ʿAbidin 1/97), Malikis (Hashiyat al-Dusuqi 1/286), and Hanbalis (Mutalib Uli al-Nuha 1/520, 538). As for smiling in the prayer, it does not invalidate it.
If he laughs unintentionally, such as seeing or hearing something and is unable to control himself from loud laughter, the jurists differed in this, and the correct view is that it does not invalidate the prayer.

An Nawawi said: Our madhhab is that smiling does not harm the prayer, and likewise laughing does not harm it unless two letters become clear from it. If two letters become clear, his prayer becomes invalid. Ibn al-Mundhir (d. 318 AH) transmitted consensus that laughter invalidates the prayer, and this is understood to refer to when two letters become clear.
Most scholars hold that there is no harm in smiling. Those who said this include Jabir ibn Abdullah (may Allah be pleased with him), Ata’ (d. 114 AH), Mujahid (d. 104 AH), al-Nakhaʿi (d. 96 AH), al-Hasan (d. 110 AH), Qatadah (d. 118 AH), al-Awzaʿi (d. 157 AH), al-Shafiʿi (d. 204 AH), and the scholars of opinion. Ibn Sirin (d. 110 AH) said: I do not know smiling except as laughter.
Al-Majmu’ Sharh al-Muhaddhab (4/21)

