Mishkat al-Masabih

Anas reported God’s Messenger as saying, “If anyone prays to God for forty days in congregation being present in time for the first takbira, two immunities will be recorded for him, one from hell and one from hypocrisy,” Tirmidhi transmitted it.

وَعَنْ أَنَسٍ قَالَ: قَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ: " مَنْ صَلَّى لِلَّهِ أَرْبَعِينَ يَوْمًا فِي جَمَاعَةٍ يُدْرِكُ التَّكْبِيرَةَ الْأُولَى كُتِبَ لَهُ بَرَاءَتَانِ: بَرَاءَةٌ مِنَ النَّارِ وَبَرَاءَةٌ مِنَ النِّفَاق ". رَوَاهُ التِّرْمِذِيّ