It is narrated from Sayyiduna Abu Hurayrah (may Allah be pleased with him) that the Messenger of Allah (peace and blessings be upon him) said: "Once a man was walking along a road when he felt severe thirst. He found a well, went down into it and drank. Then he came out and saw a dog panting and licking the moist earth because of thirst. The man said: 'This dog has suffered the same thirst that I suffered' (in the narration of Qutaybah: 'like what I suffered').
Then he went down into the well, filled his leather sock with water, held it in his mouth until he climbed up, and gave the dog water to drink. Allah Almighty appreciated his deed and forgave him." The Companions (may Allah be pleased with them) said: "Is there a reward for us even in animals?" He (peace and blessings be upon him) said: "There is a reward in (serving) every living creature with a moist liver."
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الزكاة / 7806