كتاب الحج
15  
The Book of Pilgrimage
(75)
Chapter: It is recommended to recite statements of remembrance when setting out for Hajj or any other purpose, and the best of this remembrances
(75)
باب مَا يَقُولُ إِذَا رَكِبَ إِلَى سَفَرٍ الْحَجِّ وَغَيْرِهِ ‏‏
Sahih Muslim 1342

Ibn Umar (Allah be pleased with them) reported that whenever Allah's Messenger (ﷺ) mounted his camel while setting out on a journey, he glorified Allah (uttered Allah-o-Akbar) thrice, and then said:

Hallowed is He Who subdued for us this (ride) and we were not ourselves powerful enough to use It as a ride, and we are going to return to our Lord. O Allah, we seek virtue and piety from Thee in this journey of ours and the act which pleaseth Thee. O Allah, lighten this journey of ours, and make its distance easy for us. O Allah, Thou art (our) companion during the journey, and guardian of (our) family. O Allah, I seek refuge with Thee from hardships of the journey, gloominess of the sights, and finding of evil changes in property and family on return. And he (the Holy Prophet) uttered (these words), and made this addition to them: We are returning, repentant, worshipping our Lord. and praising Him.
حَدَّثَنِي هَارُونُ بْنُ عَبْدِ اللَّهِ، حَدَّثَنَا حَجَّاجُ بْنُ مُحَمَّدٍ، قَالَ قَالَ ابْنُ جُرَيْجٍ أَخْبَرَنِي أَبُو الزُّبَيْرِ، أَنَّ عَلِيًّا الأَزْدِيَّ، أَخْبَرَهُ أَنَّ ابْنَ عُمَرَ عَلَّمَهُمْ أَنَّ رَسُولَ اللَّهِ صلى الله عليه وسلم كَانَ إِذَا اسْتَوَى عَلَى بَعِيرِهِ خَارِجًا إِلَى سَفَرٍ كَبَّرَ ثَلاَثًا ثُمَّ قَالَ ‏"‏ سُبْحَانَ الَّذِي سَخَّرَ لَنَا هَذَا وَمَا كُنَّا لَهُ مُقْرِنِينَ وَإِنَّا إِلَى رَبِّنَا لَمُنْقَلِبُونَ اللَّهُمَّ إِنَّا نَسْأَلُكَ فِي سَفَرِنَا هَذَا الْبِرَّ وَالتَّقْوَى وَمِنَ الْعَمَلِ مَا تَرْضَى اللَّهُمَّ هَوِّنْ عَلَيْنَا سَفَرَنَا هَذَا وَاطْوِ عَنَّا بُعْدَهُ اللَّهُمَّ أَنْتَ الصَّاحِبُ فِي السَّفَرِ وَالْخَلِيفَةُ فِي الأَهْلِ اللَّهُمَّ إِنِّي أَعُوذُ بِكَ مِنْ وَعْثَاءِ السَّفَرِ وَكَآبَةِ الْمَنْظَرِ وَسُوءِ الْمُنْقَلَبِ فِي الْمَالِ وَالأَهْلِ ‏"‏ ‏.‏ وَإِذَا رَجَعَ قَالَهُنَّ ‏.‏ وَزَادَ فِيهِنَّ ‏"‏ آيِبُونَ تَائِبُونَ عَابِدُونَ لِرَبِّنَا حَامِدُونَ ‏"‏ ‏.‏
Reference : Sahih Muslim 1342
In-book reference : Book 15, Hadith 479
USC-MSA web (English) reference : Book 7, Hadith 3113
  (deprecated numbering scheme)