Language:
كتاب الإيمان
2  
Belief
(19)
Chapter: If one does not embrace Islam truly but does so by compulsion or for fear of being killed (then that man is not a believer)
(19)
بَابُ إِذَا لَمْ يَكُنِ الإِسْلاَمُ عَلَى الْحَقِيقَةِ وَكَانَ عَلَى الاِسْتِسْلاَمِ أَوِ الْخَوْفِ مِنَ الْقَتْلِ
Sahih al-Bukhari 27

Narrated Sa'd:

Allah's Messenger (ﷺ) distributed (Zakat) amongst (a group of) people while I was sitting there but Allah's Messenger (ﷺ) left a man whom I thought the best of the lot. I asked, "O Allah's Messenger (ﷺ)! Why have you left that person? By Allah I regard him as a faithful believer." The Prophet (ﷺ) commented: "Or merely a Muslim." I remained quiet for a while, but could not help repeating my question because of what I knew about him. And then asked Allah's Messenger (ﷺ), "Why have you left so and so? By Allah! He is a faithful believer." The Prophet (ﷺ) again said, "Or merely a Muslim." And I could not help repeating my question because of what I knew about him. Then the Prophet (ﷺ) said, "O Sa'd! I give to a person while another is dearer to me, for fear that he might be thrown on his face in the Fire by Allah."

حَدَّثَنَا أَبُو الْيَمَانِ، قَالَ أَخْبَرَنَا شُعَيْبٌ، عَنِ الزُّهْرِيِّ، قَالَ أَخْبَرَنِي عَامِرُ بْنُ سَعْدِ بْنِ أَبِي وَقَّاصٍ، عَنْ سَعْدٍ، رضى الله عنه أَنَّ رَسُولَ اللَّهِ صلى الله عليه وسلم أَعْطَى رَهْطًا وَسَعْدٌ جَالِسٌ، فَتَرَكَ رَسُولُ اللَّهِ صلى الله عليه وسلم رَجُلاً هُوَ أَعْجَبُهُمْ إِلَىَّ فَقُلْتُ يَا رَسُولَ اللَّهِ مَا لَكَ عَنْ فُلاَنٍ فَوَاللَّهِ إِنِّي لأَرَاهُ مُؤْمِنًا‏.‏ فَقَالَ ‏"‏ أَوْ مُسْلِمًا ‏"‏‏.‏ فَسَكَتُّ قَلِيلاً، ثُمَّ غَلَبَنِي مَا أَعْلَمُ مِنْهُ فَعُدْتُ لِمَقَالَتِي فَقُلْتُ مَا لَكَ عَنْ فُلاَنٍ فَوَاللَّهِ إِنِّي لأَرَاهُ مُؤْمِنًا فَقَالَ ‏"‏ أَوْ مُسْلِمًا ‏"‏‏.‏ ثُمَّ غَلَبَنِي مَا أَعْلَمُ مِنْهُ فَعُدْتُ لِمَقَالَتِي وَعَادَ رَسُولُ اللَّهِ صلى الله عليه وسلم ثُمَّ قَالَ ‏"‏ يَا سَعْدُ، إِنِّي لأُعْطِي الرَّجُلَ وَغَيْرُهُ أَحَبُّ إِلَىَّ مِنْهُ، خَشْيَةَ أَنْ يَكُبَّهُ اللَّهُ فِي النَّارِ ‏"‏‏.‏ وَرَوَاهُ يُونُسُ وَصَالِحٌ وَمَعْمَرٌ وَابْنُ أَخِي الزُّهْرِيِّ عَنِ الزُّهْرِيِّ‏.‏
Reference : Sahih al-Bukhari 27
In-book reference : Book 2, Hadith 20
USC-MSA web (English) reference : Vol. 1, Book 2, Hadith 27
  (deprecated numbering scheme)