The Messenger of Allah ﷺ said, "Whoever's last words are 'There is no god but Allah' will enter Paradise."
قال رسول الله ﷺ: من كان آخر كلامه لا إله إلا الله دخل الجنة.
Abu Dawud (3116) narrated it from Malik bin Abdul-Wahid Mismai, who said, Dahhak bin Makhlad told us, Abdul-Hameed bin Jafar told us, Salih bin Abu Urayb told me, from Kathir bin Mura, from Muaz bin Jabal, and he related it. Hakim graded it sahih (1/351). Imam Ahmad (22034) narrated it through another route from Abdul-Hameed, meaning Ibn Jafar, with his chain. In it, Muaz said to us during his illness, "I heard something from the Messenger of Allah that I used to conceal from you. I heard the Messenger of Allah say, 'Whoever's last words are there is no god but Allah will enter Paradise.'"Salih bin Abu Urayb was narrated from by a group including Layth, Haywa bin Shurayh, Ibn Lahia, Abdul-Hameed bin Jafar Ansari, and others, but no formal validation of his reliability has come from any of the leading scholars except Ibn Hibban. With this, the obscurity of his identity is lifted, but the obscurity of his standing remains, as is known and established in the science of hadith. That is why Ibn Qattan said of him, "He is not known."It is also narrated from him, as a saying attributed to the Prophet, "There is no soul that dies bearing witness that there is no god but Allah, and that I am the Messenger of Allah, this returning to a heart of certainty, but Allah forgives it." Ibn Majah (3796) narrated this from the hadith of Yunus, from Humayd bin Hilal, from Hassan bin Kahil, from Abdul-Rahman bin Samura, from Muaz bin Jabal, and he related it. Through this same route it was also narrated by Imam Ahmad (21998), Nasai in Amal al-Yawm wal-Layla (1136), and Ibn Hibban in his Sahih (203). Its transmission hinges on Hassan bin Kahil, also said to be Kahin, from whom two narrators reported, and no one validated him except Ibn Hibban, so his standing is unknown according to the majority of the scholars of hadith. In Taqrib he is described as "acceptable," meaning when corroborated, and I have not found corroboration for him except in the general sense mentioned earlier. With this, the hadith rises to the level of having a good chain of transmission.On this subject there is also what is narrated from Huzaifa, who said, I leaned the Prophet against my chest, and he said, "Whoever says there is no god but Allah, seeking the face of Allah, and his life ends with it, will enter Paradise. Whoever fasts a day seeking the face of Allah, and his life ends with it, will enter Paradise. Whoever gives charity seeking the face of Allah, and his life ends with it, will enter Paradise." However, this chain is broken. Imam Ahmad (23324) narrated it through Hammad bin Salama, from Uthman Batti, from Naeem, Affan said in his version, Ibn Abu Hind, from Huzaifa, and he related it. But Naeem bin Abu Hind never met Huzaifa. This is the most sahih version through which this hadith has been narrated.Bazzar narrated it in Kashf Astar (1038) through another route from Hasan bin Abu Jafar, from Muhammad bin Mujada, from Naeem bin Abu Hind, from Rubai, from Huzaifa bin Yaman, in abbreviated form mentioning only fasting. Bazzar said, "We do not know of anyone who narrated it from Naeem except Muhammad, nor from him except Hasan." I say, it is as he said, for Hasan bin Abu Jafar alone transmitted this chain, and he is among those whom the majority of scholars of knowledge weakened, including Bukhari, Nasai, Ibn Madini, Ajli, Abu Hatim, and others. Hafiz described him with the words, "Weak in hadith despite his devotion and virtue."Once this is understood, the statement of Haythami in Majma (2/324), "Ahmad narrated it, and Bazzar narrated part of it concerning fasting only, and its narrators are validated as reliable," is evidence of his laxity. He likewise said in Majma (3/183), "Bazzar narrated it, and it is given at greater length by Ahmad, and it was mentioned earlier under the topic of prompting the dying person, and its narrators are validated as reliable."