Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
bayhaqi:4323Abū ʿAlī al-Ḥusayn b. Muḥammad al-Faqīh > Abū Bakr Muḥammad b. Bakr > Abū Dāwud > Musaddad > ʿAbd al-Wāḥid b. Ziyād > Aflat b. Khalīfah > Jasrah b. Dajājah > ʿĀʾishah > Jāʾ

[Machine] The Messenger of Allah ﷺ entered the mosque and found some of his companions' houses facing the mosque. He said, "Redirect these houses away from the mosque." Then, the Prophet ﷺ entered and the people did not do anything, hoping that he would give them permission to keep their houses as they were. However, the Prophet ﷺ came out to them again and said, "Redirect these houses away from the mosque, for I do not permit entry into the mosque for a menstruating woman or a sexually impure person." Abu Dawood said: "and this was the opinion of Al-A'miri." Al-Sheikh added that Moussa ibn Ismail reported it from Abdul Wahid except for the mention of Muhammad and the family of Muhammad ﷺ , which was narrated to us by Abu Bakr Muhammad ibn Ibrahim Al-Farsi. Ibrahim ibn Abdullah Al-Asbahani narrated it from Muhammad ibn Sulaiman ibn Faris, who reported it from Muhammad ibn Ismail Al-Bukhari, who mentioned it with his addition. Al-Bukhari said: "and according to Jassarat Al-Ajaa'ib, Urwah and Abbad ibn Abdullah reported from Aisha (may Allah be pleased with her) that the Prophet ﷺ closed all the doors except for Abu Bakr's door, and this is the most authentic narration." Al-Sheikh commented that if this is correct, it implies that one can stay within the boundaries of the mosque without having to pass through it, according to the evidence of the Quran.  

البيهقي:٤٣٢٣أنبأ أَبُو عَلِيٍّ الْحُسَيْنُ بْنُ مُحَمَّدٍ الْفَقِيهُ أنبأ أَبُو بَكْرٍ مُحَمَّدُ بْنُ بَكْرٍ ثنا أَبُو دَاوُدَ ثنا مُسَدَّدٌ ثنا عَبْدُ الْوَاحِدِ بْنُ زِيَادٍ ثنا أَفْلَتُ بْنُ خَلِيفَةَ حَدَّثَتْنِي جَسْرَةُ بِنْتُ دَجَاجَةَ قَالَتْ سَمِعْتُ عَائِشَةَ ؓ تَقُولُ

جَاءَ رَسُولُ اللهِ ﷺ وَوُجُوهُ بُيُوتِ أَصْحَابِهِ شَارِعَةٌ فِي الْمَسْجِدِ فَقَالَ وَجِّهُوا هَذِهِ الْبُيُوتَ عَنِ الْمَسْجِدِ ثُمَّ دَخَلَ النَّبِيُّ ﷺ وَلَمْ يَصْنَعِ الْقَوْمُ شَيْئًا رَجَاءَ أَنْ تَنْزِلَ لَهُمْ رُخْصَةٌ فَخَرَجَ إِلَيْهِمْ بَعْدُ فَقَالَ وَجِّهُوا هَذِهِ الْبُيُوتَ عَنِ الْمَسْجِدِ؛ فَإِنِّي لَا أُحِلُّ الْمَسْجِدَ لِحَائِضٍ وَلَا جُنُبٍ قَالَ أَبُو دَاوُدَ وَهُوَ فُلَيْتٌ الْعَامِرِيُّ 4324 قَالَ الشَّيْخُ زَادَ فِيهِ مُوسَى بْنُ إِسْمَاعِيلَ عَنْ عَبْدِ الْوَاحِدِ إِلَّا لِمُحَمَّدٍ ﷺ وَآلِ مُحَمَّدٍ أَخْبَرَنَاهُ أَبُو بَكْرٍ مُحَمَّدُ بْنُ إِبْرَاهِيمَ الْفَارِسِيُّ ثنا إِبْرَاهِيمُ بْنُ عَبْدِ اللهِ الْأَصْبَهَانِيُّ ثنا مُحَمَّدُ بْنُ سُلَيْمَانَ بْنِ فَارِسٍ ثنا مُحَمَّدُ بْنُ إِسْمَاعِيلَ الْبُخَارِيُّ ثنا مُوسَى فَذَكَرَهُ بِزِيَادَتِهِ قَالَ الْبُخَارِيُّ وَعِنْدَ جَسْرَةَ عَجَائِبُ قَالَ الْبُخَارِيُّ وَقَالَ عُرْوَةُ وَعَبَّادُ بْنُ عَبْدِ اللهِ عَنْ عَائِشَةَ ؓ عَنِ النَّبِيِّ ﷺ سُدُّوا هَذِهِ الْأَبْوَابَ إِلَّا بَابَ أَبِي بَكْرٍ وَهَذَا أَصَحُّ قَالَ الشَّيْخُ وَهَذَا إِنْ صَحَّ فَمَحْمُولٌ فِي الْجُنُبِ عَلَى الْمُكْثِ فِيهِ دُونَ الْعُبُورِ بِدَلِيلِ الْكِتَابِ