(Imam Bukhari narrates that) Muslim bin Ibrahim narrated to us, he says: Hisham narrated to us, he says: Qatadah narrated to us, from Hazrat Anas (may Allāh be pleased with him), from the Prophet ﷺ, he said:
That person will come out of the Fire who said "La ilaha illallah" and had even a barley grain's weight of goodness in his heart, and that person will come out of the Fire who said "La ilaha illallah" and had even a wheat grain's weight of goodness in his heart, and that person will come out of the Fire who said "La ilaha illallah" and had even an atom's weight (or a millet grain's weight) of goodness in his heart.
Imam Bukhari says: Aban said: Qatadah narrated to us, he said: Hazrat Anas (may Allāh be pleased with him) narrated to us, from the Prophet ﷺ; in it, instead of the word "goodness," the word "faith" is used.
حَدَّثَنَا مُسْلِمُ بْنُ إِبْرَاهِيمَ قَالَ: حَدَّثَنَا هِشَامٌ قَالَ: حَدَّثَنَا قَتَادَةُ، عَنْ أَنَسٍ، عَنِ النَّبِيِّ ﷺ قَالَ
يَخْرُجُ مِنَ النَّارِ مَنْ قَالَ لَا إِلَهَ إِلَّا اللهُ وَفِي قَلْبِهِ وَزْنُ شَعِيرَةٍ مِنْ خَيْرٍ، وَيَخْرُجُ مِنَ النَّارِ مَنْ قَالَ لَا إِلَهَ إِلَّا اللهُ وَفِي قَلْبِهِ وَزْنُ بُرَّةٍ مِنْ خَيْرٍ، وَيَخْرُجُ مِنَ النَّارِ مَنْ قَالَ لَا إِلَهَ إِلَّا اللهُ وَفِي قَلْبِهِ وَزْنُ ذَرَّةٍ مِنْ خَيْرٍ.
Reference: Sahih Al Bukhari 44