Mishkat al-Masabih 941
وَعَنِ ابْنِ عَبَّاسٍ رَضِيَ اللَّهُ عَنْهُمَا: أَنَّ النَّبِيَّ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ كَانَ يُعَلِّمُهُمْ هَذَا الدُّعَاءَ كَمَا يُعَلِّمُهُمُ السُّورَةَ مِنَ الْقُرْآنِ يَقُولُ: «قُولُوا اللَّهُمَّ إِنِّي أَعُوذُ بِكَ مِنْ عَذَابِ جَهَنَّمَ وَأَعُوذُ بِكَ مِنْ عَذَابِ الْقَبْرِ وَأَعُوذُ بِكَ مِنْ فِتْنَةِ الْمَسِيحِ الدَّجَّالِ وَأَعُوذُ بِكَ مِنْ فِتْنَةِ الْمَحْيَا وَالْمَمَاتِ» . رَوَاهُ مُسْلِمٌ
And from Ibn ʿAbbas, may Allah be pleased with them both: The Prophet ﷺ used to teach them this supplication as he taught them a surah of the Quran. He would say: "Say: O Allah, I seek refuge in You from the punishment of Hell, I seek refuge in You from the punishment of the grave, I seek refuge in You from the trial of the False Messiah, and I seek refuge in You from the trial of life and death." Reported by Muslim.