ENOfficial
Narrated Nafi`: Ibn `Umar used to kill snakes but when Abu Lubaba informed him that the Prophet (ﷺ) had forbidden the killing of snakes living in houses, he gave up killing them.
Source: sunnah.com
Other translations
Arabic
حَدَّثَنَا مَالِكُ بْنُ إِسْمَاعِيلَ، حَدَّثَنَا جَرِيرُ بْنُ حَازِمٍ، عَنْ نَافِعٍ، عَنِ ابْنِ عُمَرَ، أَنَّهُ كَانَ يَقْتُلُ الْحَيَّاتِ. فَحَدَّثَهُ أَبُو لُبَابَةَ، أَنَّ النَّبِيَّ صلى الله عليه وسلم نَهَى عَنْ قَتْلِ جِنَّانِ الْبُيُوتِ، فَأَمْسَكَ عَنْهَا.
sunnah.com