Hadith 1098

وَقَالَ اللَّيْثُ : حَدَّثَنِي يُونُسُ ، عَنْ ابْنِ شِهَابٍ ، قَالَ : قَالَ سَالِمٌ : كَانَ عَبْدُ اللَّهِ يُصَلِّي عَلَى دَابَّتِهِ مِنَ اللَّيْلِ وَهُوَ مُسَافِرٌ مَا يُبَالِي حَيْثُ مَا كَانَ وَجْهُهُ ، قَالَ ابْنُ عُمَرَ : " وَكَانَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ يُسَبِّحُ عَلَى الرَّاحِلَةِ قِبَلَ أَيِّ وَجْهٍ تَوَجَّهَ وَيُوتِرُ عَلَيْهَا ، غَيْرَ أَنَّهُ لَا يُصَلِّي عَلَيْهَا الْمَكْتُوبَةَ " .
Narrated Salim: At night `Abdullah bin `Umar used to offer the prayer on the back of his animal during the journey and never cared about the direction he faced. Ibn `Umar said, "Allah's Apostle used to offer the optional prayer on the back of his Mount facing any direction and also used to pray the witr on it but never offered the compulsory prayer on it."
Hadith Reference صحيح البخاري / كتاب تقصير الصلاة / 1098
Hadith Grading محدثین: أحاديث صحيح البخاريّ كلّها صحيحة
Explanation & Benefits
Maulana Dawood Raz
Hadith Commentary:
It is understood that for obligatory prayer (fard salah), one would dismount from the animal, because it is not valid to perform it while mounted; there is consensus (ijma‘) of the scholars on this matter.
By "mount" (sawari), camels, horses, mules, etc. are meant.
Prayer performed on a train is valid.
Source: Sahih Bukhari: Commentary by Maulana Dawood Raz, Page: 1098