Sahih al-Bukhari 4269
Narration text is preserved in its supplied Arabic and English. Translated interfaces and reading guides do not add narration translations in other languages.
يَا أُسَامَةُ أَقَتَلْتَهُ بَعْدَ مَا قَالَ لاَ إِلَهَ إِلاَّ اللَّهُ "
Narrated Usama bin Zaid:
Allah's Messenger (ﷺ) sent us towards Al-Huruqa, and in the morning we attacked them and defeated them. I and an Ansari man followed a man from among them and when we took him over, he said, "La ilaha illal-Lah." On hearing that, the Ansari man stopped, but I killed him by stabbing him with my spear. When we returned, the Prophet (ﷺ) came to know about that and he said, "O Usama! Did you kill him after he had said "La ilaha ilal-Lah?" I said, "But he said so only to save himself." The Prophet (ﷺ) kept on repeating that so often that I wished I had not embraced Islam before that day.
Full reference and source
Sahih al-Bukhari 4269 In-book : Book 64, Hadith 303 USC-MSA web (English) : Vol. 5, Book 59, Hadith 568 (deprecated)
View source on Sunnah.com (opens in a new tab)