(68) باب اسْتِحْبَابِ دُخُولِ الْكَعْبَةِ لِلْحَاجِّ وَغَيْرِهِ وَالصَّلاَةِ فِيهَا وَالدُّعَاءِ فِي نَوَاحِيهَا كُلِّهَا
Abdullah b. Umar reported that he reached the Ka'ba and Allah's Apostle (ﷺ) had entered therein, and Bilal and Usama too. 'Uthman b. Talha closed the door to them, and they stayed there for a considerable time, and then the door was opend and Allah's Apostle (ﷺ) came out, and I went upstairs and entered the House and said:
Where did Allah's Apostle (ﷺ) observe prayer? They said: At this very place. I, however, forgot to ask them about the (number of) rak'ahs that he observed.
Reference: Sahih Muslim 1329 e
In-book reference: Book 15, Hadith 438
USC-MSA web (English) reference(deprecated numbering scheme): Book 7, Hadith 3072