It wasnarrated from 'Abdullah bin Mughaffal that the Messenger ofAllah(ﷺ) said:
"Were it not that dogs form one of the communities(ornations – of creatures), I would have commanded that they bekilled. But kill those that are all black. There are no people whokeep a dog, except for dogs used for herding livestock, hunting orfarming, but two Qirat will be deducted from their reward each day." (ES)
English reference (ES): Vol. 4, Book 28, Hadith 3205 (ES)
Arabic reference (ES): Book 28, Hadith 3326 (ES)