عَنْ أَبِي هُرَيْرَةَ قَالَ: قَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ: «كُلُّ ذِي نَابٍ منَ السِّباعِ فأكلُه حرامٌ» . رَوَاهُ مُسلم
Translation
Ibn ‘Umar told of hearing the Prophet say, "Kill snakes, kill those which have two streaks and those with small tails, for they obliterate the eyesight and cause miscarriage." ‘Abdallah [i.e. Ibn Umar] said that while he was chasing a snake and trying to kill it Abu Lubaba called to him not to kill it, but he replied that God's messenger had given command that snakes should be killed. He then said that he had later prohibited killing house-snakes, for they are resident jinn. (Bukhari and Muslim.)