Furthermore, even though this ḥadith was originally narrated about a voluntary prayer, it appears that an obligatory prayer is equally valid inside the Kaʿbah, for the general rules governing both obligatory and supererogatory prayers—whether in what is required, forbidden, or merely permitted—are the same, except where the Lawgiver has made a specific exception, and no such exception exists in this case.
The ḥadith comes through the narration of ʿAbdullāh ibn ʿUmar (may Allah be pleased with him). It was recorded by al-Bukhārī, Muslim, Mālik, Abū Dāwūd, al-Nasāʾī, al-Tirmidhī, al-Dārimī, Ibn Mājah, al-Ṭaḥāwī, al-Bayhaqī, al-Ṭayālisī, and Aḥmad through numerous chains, both lengthy and abridged, from Nāfiʿ who said:
“On the Day of Conquest the Messenger of Allah ﷺ arrived and dismounted in the courtyard of the Kaʿbah. He sent for ʿUthmān ibn Ṭalḥah, who brought the key and opened the door. The Prophet ﷺ then entered, together with Bilāl, Usāmah ibn Zayd, and ʿUthmān ibn Ṭalḥah. He told them to close the door, and they stayed inside for some time. When the door was opened, ʿAbdullāh (ibn ʿUmar) said: I hurried ahead of the people and met the Messenger of Allah ﷺ as he was coming out, with Bilāl right behind him. I asked Bilāl, ‘Did the Messenger of Allah ﷺ pray inside?’ He replied, ‘Yes.’ I asked, ‘Where did he pray?’ He said, ‘Between the two pillars, facing the qiblah.’ ʿAbdullāh added, ‘I forgot to ask him how many units he prayed.’”
This wording is Muslim’s. Al-Tirmidhī also relates the report in a much-abridged form that mentions only the prayer, and it includes the first additional detail. That same addition is likewise transmitted by Muslim through another chain from Ibn Shihāb, who said: “Sālim ibn ʿAbdullāh informed me from his father something to the same effect.”