Sahih al-Bukhari 1815
Narration text is preserved in its supplied Arabic and English. Translated interfaces and reading guides do not add narration translations in other languages.
حَدَّثَنَا أَبُو نُعَيْمٍ، حَدَّثَنَا سَيْفٌ، قَالَ حَدَّثَنِي مُجَاهِدٌ، قَالَ سَمِعْتُ عَبْدَ الرَّحْمَنِ بْنَ أَبِي لَيْلَى، أَنَّ كَعْبَ بْنَ عُجْرَةَ، حَدَّثَهُ قَالَ وَقَفَ عَلَىَّ رَسُولُ اللَّهِ صلى الله عليه وسلم بِالْحُدَيْبِيَةِ، وَرَأْسِي يَتَهَافَتُ قَمْلاً فَقَالَ يُؤْذِيكَ هَوَامُّكَ ". قُلْتُ نَعَمْ. قَالَ " فَاحْلِقْ رَأْسَكَ ـ أَوْ قَالَ ـ احْلِقْ ". قَالَ فِيَّ نَزَلَتْ هَذِهِ الآيَةُ {فَمَنْ كَانَ مِنْكُمْ مَرِيضًا أَوْ بِهِ أَذًى مِنْ رَأْسِهِ} إِلَى آخِرِهَا. فَقَالَ النَّبِيُّ صلى الله عليه وسلم " صُمْ ثَلاَثَةَ أَيَّامٍ، أَوْ تَصَدَّقْ بِفَرَقٍ بَيْنَ سِتَّةٍ، أَوِ انْسُكْ بِمَا تَيَسَّرَ "."
Narrated Ka`b bin `Umra:
Allah's Messenger (ﷺ) stood beside me at Al-Hudaibiya and the lice were falling from my head in great number. He asked me, "Have your lice troubled you?" I replied in the affirmative. He ordered me to get my head shaved. Ka`b added, "This Holy Verse:--'And if any of you is ill, or has ailment in his scalp (2:196), etc. was revealed regarding me. "The Prophet (ﷺ) then ordered me either to fast three days, or to feed six poor persons with one Faraq (three Sas) (of dates), or to slaughter a sheep, etc. (sacrifice) whatever was available.
Full reference and source
Sahih al-Bukhari 1815 In-book : Book 27, Hadith 10 USC-MSA web (English) : Vol. 3, Book 28, Hadith 42 (deprecated)
View source on Sunnah.com (opens in a new tab)