The Prophet ﷺ prayed inside the Kaabah.Ibn Abbas said, "He did not pray, but he made the takbir."
حدثنا قتيبة حدثنا حماد بن زيد عن عمرو بن دينار عن ابن عمر
أن النبي ﷺ صلى في جوف الكعبة قال ابن عباس لم يصل ولكنه كبر
[Its chain of transmission is sahih]. Nasai narrated it in shortened form (219/5, no. 2916) (Rites of Hajj, chapter on takbir in the corners of the Kaaba), from the hadith of Ibn Abbas alone. Ibn Khuzayma also narrated it (no. 3008), and so did Ahmad (15/6, no. 24416), from the hadith of Hammad bin Zayd, from Amr bin Dinar, from Abdullah bin Umar, from Bilal, with the same wording.On this subject there is also a report from Usama bin Zayd [Muslim, no. 1330, though he did not pray, and the permissibility of praying is found in Ahmad 201/5], and from Fadl bin Abbas [Ahmad 1/210, 212, 21, though he did not pray], and from Uthman bin Talha [Ahmad 410/3], and from Shayba bin Uthman [Tabarani in al-Kabir, 357/7, no. 7190].