The Messenger of Allah ﷺ said, "Whoever's final words are 'There is no god but Allah' will enter Paradise."
حدثنا مالك بن عبد الواحد المسمعي حدثنا الضحاك بن مخلد حدثنا عبد الحميد بن جعفر حدثني صالح بن أبي عريب عن كثير بن مرة
قال رسول الله ﷺ من كان آخر كلامه لا إله إلا الله دخل الجنة
[Its isnad is hasan] Ahmad narrated it in 5/247, from Abu Asim Dahhak bin Mukhlad, through him. Hakim graded it sahih in 1/351, 500, and Dhahabi agreed with him. The hadith has corroborating narrations in Ibn Hibban, no. 719, and elsewhere.