Sunan Abi Dawud, Book 41, Hadith 5041 (USC-MSA)

‘Ubadah b. al-Samit reported the Messenger of Allah (May peace be upon him) as saying; If anyone is alarmed while asleep and he says when awakes : there is no god but Allah alone Who has no partner, to whom dominion belongs, to whom praise is due, and who has power over everything (omnipotent). Glory be to Allah, and praise be to Allah, and there is no god but Allah, and then he prays: O my Lord, forgive me. Abu Dawud said : Al-Walid’s version has; and he prays, his prayer will be answered. If he gets up, performs ablution, and prays, his prayer will be accepted.

حَدَّثَنَا عَبْدُ الرَّحْمَنِ بْنُ إِبْرَاهِيمَ الدِّمَشْقِيُّ، حَدَّثَنَا الْوَلِيدُ، قَالَ قَالَ الأَوْزَاعِيُّ حَدَّثَنِي عُمَيْرُ بْنُ هَانِئٍ، قَالَ حَدَّثَنِي جُنَادَةُ بْنُ أَبِي أُمَيَّةَ، عَنْ عُبَادَةَ بْنِ الصَّامِتِ، قَالَ قَالَ رَسُولُ اللَّهِ صلى الله عليه وسلم ‏"‏ مَنْ تَعَارَّ مِنَ اللَّيْلِ فَقَالَ حِينَ يَسْتَيْقِظُ لاَ إِلَهَ إِلاَّ اللَّهُ وَحْدَهُ لاَ شَرِيكَ لَهُ لَهُ الْمُلْكُ وَلَهُ الْحَمْدُ وَهُوَ عَلَى كُلِّ شَىْءٍ قَدِيرٌ سُبْحَانَ اللَّهِ وَالْحَمْدُ لِلَّهِ وَلاَ إِلَهَ إِلاَّ اللَّهُ وَاللَّهُ أَكْبَرُ وَلاَ حَوْلَ وَلاَ قُوَّةَ إِلاَّ بِاللَّهِ ثُمَّ دَعَا رَبِّ اغْفِرْ لِي ‏"‏ ‏.‏ قَالَ الْوَلِيدُ أَوْ قَالَ ‏"‏ دَعَا اسْتُجِيبَ لَهُ فَإِنْ قَامَ فَتَوَضَّأَ ثُمَّ صَلَّى قُبِلَتْ صَلاَتُهُ ‏"‏ ‏.‏

sunnah.com