كتاب صلاة المسافرين وقصرها
6  
The Book of Prayer - Travellers
(31)
Chapter: The command to one who becomes sleepy while praying, or who starts to falter in his recitation of the Qur’an or statements of remembrance, to lie down or sit down until that goes away
(31)
باب أَمْرِ مَنْ نَعَسَ فِي صَلاَتِهِ أَوِ اسْتَعْجَمَ عَلَيْهِ الْقُرْآنُ أَوِ الذِّكْرُ بِأَنْ يَرْقُدَ أَوْ يَقْعُدَ حَتَّى يَذْهَبَ عَنْهُ ذَلِكَ
Sahih Muslim 785 b

'A'isha said:

The Messenger of Allah (ﷺ) came to me when a woman was sitting with me. He said: Who is she? I said: She is a woman who does not sleep but prays. He said: Do such acts which you are capable of doing. By Allah, Allah does not grow weary but you will grow weary. The religious act most pleasing to Him is one the doer of which does it continuously. (And in the hadith transmitted by Abu Usama [the words are]:" She was a woman from Banu Asad." )
حَدَّثَنَا أَبُو بَكْرِ بْنُ أَبِي شَيْبَةَ، وَأَبُو كُرَيْبٍ قَالَ حَدَّثَنَا أَبُو أُسَامَةَ، عَنْ هِشَامِ بْنِ، عُرْوَةَ ح وَحَدَّثَنِي زُهَيْرُ بْنُ حَرْبٍ، - وَاللَّفْظُ لَهُ - حَدَّثَنَا يَحْيَى بْنُ سَعِيدٍ، عَنْ هِشَامٍ، قَالَ أَخْبَرَنِي أَبِي، عَنْ عَائِشَةَ، قَالَتْ دَخَلَ عَلَىَّ رَسُولُ اللَّهِ صلى الله عليه وسلم وَعِنْدِي امْرَأَةٌ فَقَالَ ‏"‏ مَنْ هَذِهِ ‏"‏ ‏.‏ فَقُلْتُ امْرَأَةٌ لاَ تَنَامُ تُصَلِّي ‏.‏ قَالَ ‏"‏ عَلَيْكُمْ مِنَ الْعَمَلِ مَا تُطِيقُونَ فَوَاللَّهِ لاَ يَمَلُّ اللَّهُ حَتَّى تَمَلُّوا ‏"‏ ‏.‏ وَكَانَ أَحَبَّ الدِّينِ إِلَيْهِ مَا دَاوَمَ عَلَيْهِ صَاحِبُهُ وَفِي حَدِيثِ أَبِي أُسَامَةَ أَنَّهَا امْرَأَةٌ مِنْ بَنِي أَسَدٍ ‏.‏
Reference : Sahih Muslim 785b
In-book reference : Book 6, Hadith 262
USC-MSA web (English) reference : Book 4, Hadith 1717
  (deprecated numbering scheme)