Language:
كتاب الاعتكاف
33  
Retiring to a Mosque for Remembrance of Allah (I'tikaf)
(3)
Chapter: Mu'takif not to enter the house except for a need.
(3)
باب لاَ يَدْخُلُ الْبَيْتَ إِلاَّ لِحَاجَةٍ
Sahih al-Bukhari 2029

Narrated `Aisha:

(the wife of the Prophet) Allah's Messenger (ﷺ) used to let his head in (the house) while he was in the mosque and I would comb and oil his hair. When in I`tikaf he used not to enter the house except for a need.

حَدَّثَنَا قُتَيْبَةُ، حَدَّثَنَا لَيْثٌ، عَنِ ابْنِ شِهَابٍ، عَنْ عُرْوَةَ، وَعَمْرَةَ بِنْتِ عَبْدِ الرَّحْمَنِ، أَنَّ عَائِشَةَ ـ رضى الله عنها ـ زَوْجَ النَّبِيِّ صلى الله عليه وسلم قَالَتْ وَإِنْ كَانَ رَسُولُ اللَّهِ صلى الله عليه وسلم لَيُدْخِلُ عَلَىَّ رَأْسَهُ وَهْوَ فِي الْمَسْجِدِ فَأُرَجِّلُهُ، وَكَانَ لاَ يَدْخُلُ الْبَيْتَ إِلاَّ لِحَاجَةٍ، إِذَا كَانَ مُعْتَكِفًا
Reference : Sahih al-Bukhari 2029
In-book reference : Book 33, Hadith 5
USC-MSA web (English) reference : Vol. 3, Book 33, Hadith 246
  (deprecated numbering scheme)