باب النهي من أكل ثومًا أو بصلا أو كراثًا أو غيره مما له رائحة كريهة عن دخول المسجد قبل زوال رائحته إلا لضرورة
This chapter deals with a courtesy of the mosque that touches on our fellow worshippers: a person who has eaten raw garlic or onion is told to keep away until the smell is gone. The concern is the comfort of those praying shoulder to shoulder, and the dignity of an assembly gathered for Allah.
The guidance is about a strong, lingering odour, not about the foods themselves, which remain permissible to eat. Notice the gentle reasoning given: what offends people also offends the angels, so removing a needless source of discomfort is part of good character in shared worship.
Hadith 1701
Ibn 'Umar (May Allah be pleased with them) said:
عن ابن عمر رضي الله عنه أن النبي صلى الله عليه وسلم قال: "من أكل من هذه الشجرة -يعني الثوم- فلا يقربن مسجدنا" ((متفق عليه)). وفي رواية لمسلم: "مساجدنا".
The Prophet (ﷺ) said, "He who has eaten garlic should not come to our mosque." [Al-Bukhari and Muslim]. The narration in Muslim is: "He who has eaten garlic should not come to our mosques."
In plain words
Eating raw garlic and then coming to the mosque is discouraged, out of care for the comfort of fellow worshippers gathered for prayer.
Reference : Riyad as-Salihin 1701 In-book reference : Book 17, Hadith 191
Hadith 1702
Anas (May Allah be pleased with him) said:
وعن أنس رضي الله عنه قال: قال النبي صلى الله عليه وسلم : "من أكل من هذه الشجرة، فلا يقربنا، ولا يصلين معنا" ((متفق عليه)).
The Prophet (ﷺ) said, "He who has eaten from this plant (i.e., garlic) should not approach us and should not offer Salat (prayer) along with us." [Al- Bukhari and Muslim].
In plain words
One who has eaten garlic is told to keep away from the congregation until the smell is gone, so others praying nearby are not bothered.
Reference : Riyad as-Salihin 1702 In-book reference : Book 17, Hadith 192
Hadith 1703
Jabir (May Allah be pleased with him) said:
وعن جابر رضي الله عنه قال: قال النبي صلى الله عليه وسلم : "من أكل ثومًا أو بصلا فليعتزلنا، أو فليعتزل مسجدنا" ((متفق عليه)). وفي رواية لمسلم: "من أكل البصل، والثوم، الكراث، فلا يقربن مسجدنا، فإن الملائكة تتأذى مما يتأذى منه بنو آدم".
The Prophet (ﷺ) said, "He who has eaten garlic or onion should keep away from us or our mosques." [Al-Bukhari and Muslim]. The narration in Muslim is: "He who has eaten onion or garlic or leek should not approach our mosque, because the angels are also offended by the strong smells) that offend the children of Adam." [Muslim].
In plain words
Whoever eats garlic, onion, or leek should stay away from the mosque until the odour fades, since the strong smell that offends people also offends the angels. Courtesy in shared worship.
Reference : Riyad as-Salihin 1703 In-book reference : Book 17, Hadith 193
Hadith 1704
It has been narrated that 'Umar (May Allah be pleased with him) said in the sermon of Friday prayer:
وعن عمر بن الخطاب رضي الله عنه أنه خطب يوم الجمعة فقال في خطبته: ثم إنكم أيها الناس تأكلون شجرتين ما أراهما إلا خبيثتين: البصل، والثوم -لقد رأيت رسول الله صلى الله عليه وسلم إذا وجد ريحهما من الرجل في المسجد أمر به، فأخرج إلى البقيع، فمن أكلهما، فليمتهما طبخًا. ((رواه مسلم)).
"O you people! You eat garlic and onion. I think the odour of these to be very offensive. I saw that if the Messenger of Allah (ﷺ) happened to find a man with such offensive odour in the mosque, he would order him to be taken out of the mosque and sent to Al-Baqi'. He who wants to eat any of these, should cook them till their odour dies out. [Muslim].
In plain words
'Umar reminded people that a strong odour from raw garlic or onion is offensive in the mosque, advising that such foods be cooked until the smell dies. The lingering smell in shared space is the issue, not the food.
Reference : Riyad as-Salihin 1704 In-book reference : Book 17, Hadith 194