(10) باب مَنْ لَقِيَ اللَّهَ بِالإِيمَانِ وَهُوَ غَيْرُ شَاكٍّ فِيهِ دَخَلَ الْجَنَّةَ وَحَرُمَ عَلَى النَّارِ
It is narrated on the authority of Sunabihi that he went to Ubada b. Samit when he was about to die. I burst into tears. Upon this he said to me:
Allow me some time (so that I may talk with you). Why do you weep? By Allah, if I am asked to bear witness, I would certainly testify for you (that you are a believer). Should I be asked to intercede, I would certainly intercede for you, and if I have the power, I would certainly do good to you, and then observed: By Allah, never did I hear anything from the Messenger of Allah (ﷺ) which could have been a source of benefit to you and then not conveyed it to you except this single hadith. That I intend to narrate to you today, since I am going to breathe my last. I heard the Messenger of Allah (ﷺ) say: He who testifies that there is no god but Allah and that Muhammad is the messenger of Allah, Allah would prohibit the fire of Hell for him.
Reference: Sahih Muslim 29
In-book reference: Book 1, Hadith 49
USC-MSA web (English) reference(deprecated numbering scheme): Book 1, Hadith 45