Hadith on Satan: Shaytan withdraws when Allah is remembered

Mu’adh ibn Jabal reported: The Messenger of Allah, peace and blessings be upon him, said, “Verily, Satan has a snout like that of a dog positioned over the son of Adam, reminding him of his lusts and his pleasures, bringing him vain hopes and bringing his whisperings to incite doubt in his Lord. When the servant says, ‘I seek refuge in Allah, the Seeing, the Knowing, from the cursed Satan, I seek refuge in Allah lest they be present with me, for Allah alone is the Seeing and the Knowing.’ Then, Satan withdraws his snout from over his heart.

Source: Zahr al-Firdaws 795

Grade: Sahih (authentic) according to Al-Shawkani

عن معاذ بن جبل قَالَ قَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ إِنَّ إِبْلِيسَ لَهُ خُرْطُومٌ كَخُرطُومِ الكَلْبِ واضِعُهُ علَى قَلْب ابْنِ آدَمَ يُذَكِّرُهُ الشَّهَوَات واللَّذاتِ ويأتِيه بِالأَمَانىِّ ويأتِيهِ بِالْوَسْوَسَةِ علَى قَلبِه لَيُشكِّكَهُ فِى رَبِّه فَإِذَا قَالَ العبْدُ أعُوذُ باللَّه السَّميع العَلِيم مِنَ الشّيْطَانِ الرَّجيم وَأَعُوذُ باللَّه أن يَحضُرُون إِنَّ اللَّهَ هُوَ السَّمِيعُ العَليِمُ خَنَسَ الخُرْطُومُ عَن القَلْب

795 زهر الفردوس

40 المحدث الشوكاني خلاصة حكم المحدث صحيح  في رفع البأس عن حديث النفس