5. The Book of Mosques and Places of Prayer
٥۔ كتاب الْمَسَاجِدِ وَمَوَاضِعِ الصَّلاَةِ
Messenger of Allah ﷺ prayed facing Baitul-Maqdis for sixteen or seventeen months but he loved to face the Kaʿba (at Mecca) so Allah revealed: "Verily, We have seen the turning of your face to the heaven!" (2:144) So the Prophet ﷺ faced the Kaʿba and the fools amongst the people namely "the Jews" said, "What has turned them from their Qibla (Baitul-Maqdis) which they formerly observed"" (Allah revealed): "Say: 'To Allah belongs the East and the West. He guides whom he will to a straight path'." (2:142) A man prayed with the Prophet (facing the Kaʿba) and went out. He saw some of the Ansar praying the ʿAsr prayer with their faces towards Baitul-Maqdis, he said, "I bear witness that I prayed with Messenger of Allah ﷺ facing the Kaʿba." So all the people turned their faces towards the Kaʿba.
كَانَ رَسُولُ اللَّهِ ﷺ صَلَّى نَحْوَ بَيْتِ الْمَقْدِسِ سِتَّةَ عَشَرَ أَوْ سَبْعَةَ عَشَرَ شَهْرًا وَكَانَ رَسُولُ اللَّهِ ﷺ يُحِبُّ أَنْ يُوَجَّهَ إِلَى الْكَعْبَةِ فَأَنْزَلَ اللَّهُ {قَدْ نَرَى تَقَلُّبَ وَجْهِكَ فِي السَّمَاءِ} فَتَوَجَّهَ نَحْوَ الْكَعْبَةِ وَقَالَ السُّفَهَاءُ مِنَ النَّاسِ وَهُمُ الْيَهُودُ مَا وَلاَّهُمْ عَنْ قِبْلَتِهِمُ الَّتِي كَانُوا عَلَيْهَا {قُلْ لِلَّهِ الْمَشْرِقُ وَالْمَغْرِبُ يَهْدِي مَنْ يَشَاءُ إِلَى صِرَاطٍ مُسْتَقِيمٍ} فَصَلَّى مَعَ النَّبِيِّ ﷺ رَجُلٌ ثُمَّ خَرَجَ بَعْدَ مَا صَلَّى فَمَرَّ عَلَى قَوْمٍ مِنَ الأَنْصَارِ فِي صَلاَةِ الْعَصْرِ نَحْوَ بَيْتِ الْمَقْدِسِ فَقَالَ هُوَ يَشْهَدُ أَنَّهُ صَلَّى مَعَ رَسُولِ اللَّهِ ﷺ وَأَنَّهُ تَوَجَّهَ نَحْوَ الْكَعْبَةِ فَتَحَرَّفَ الْقَوْمُ حَتَّى تَوَجَّهُوا نَحْوَ الْكَعْبَةِ
We prayed along with the Prophet ﷺ facing Jerusalem for sixteen or seventeen months. Then Allah ordered him to turn his face towards the Qibla (in Mecca):-- "And from whence-so-ever you start forth (for prayers) turn your face in the direction of (the Sacred Mosque of Mecca) Al-Masjid-ul Haram.." (2.149)
صَلَّيْنَا مَعَ النَّبِيِّ ﷺ نَحْوَ بَيْتِ الْمَقْدِسِ سِتَّةَ عَشَرَ أَوْ سَبْعَةَ عَشَرَ شَهْرًا ثُمَّ صَرَفَهُ نَحْوَ الْقِبْلَةِ
While the people were offering the Fajr prayer at Quba' (near Medina), someone came to them and said: "It has been revealed to Messenger of Allah ﷺ tonight, and he has been ordered to pray facing the Kaʿba." So turn your faces to the Kaʿba. Those people were facing Sham (Jerusalem) so they turned their faces towards Kaʿba (at Mecca).
بَيْنَا النَّاسُ بِقُبَاءٍ فِي صَلاَةِ الصُّبْحِ إِذْ جَاءَهُمْ آتٍ فَقَالَ إِنَّ رَسُولَ اللَّهِ ﷺ قَدْ أُنْزِلَ عَلَيْهِ اللَّيْلَةَ قُرْآنٌ وَقَدْ أُمِرَ أَنْ يَسْتَقْبِلَ الْكَعْبَةَ فَاسْتَقْبِلُوهَا وَكَانَتْ وُجُوهُهُمْ إِلَى الشَّأْمِ فَاسْتَدَارُوا إِلَى الْكَعْبَةِ