Abu Huraira reported: The Messenger of Allah, peace and blessings be upon him, said, “Verily, the people will only be resurrected for judgment based upon their intentions.”
Source: Sunan Ibn Mājah 4229
Grade: Sahih li ghayrihi (authentic due to external evidence) according to Al-Albani
عَنْ أَبِي هُرَيْرَةَ قَالَ قَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ إِنَّمَا يُبْعَثُ النَّاسُ عَلَى نِيَّاتِهِمْ
4229 سنن ابن ماجه كتاب الزهد باب النية
13 المحدث الألباني خلاصة حكم المحدث صحيح لغيره في صحيح الترغيب