It was narrated that Ibn Umar said:
The Messenger of Allah entered the Kabah, and was about to come out, when I thought of something, so I came quickly and I found the Messenger of Allah coming out. I asked Bilal: Did the Messenger of Allah prayed inside the Kabah?' He said: 'Yes, two Rakahs between the two columns.'