Ibn ‘Umar and Abu Huraira reported God’s messenger as saying,
“A woman was punished on account of a cat which she kept shut up till it died of hunger. She did not feed it or let it out so that it might eat things creeping on the earth.”
Abu Huraira reported God’s messenger as saying,
“Forgiveness was granted to an unchaste woman who coming upon a dog panting and almost dead with thirst at the mouth of a well, took off her shoe, tied it with her head-covering, and drew some water for it. On that account she was forgiven.” He was asked whether people received a reward for what they did to animals, and replied, “A reward is given in connection with every living creature.”*
(Bukhari and Muslim.)
* Literally, everything possessed of a moist liver.
Abu Huraira reported God’s messenger as saying,
“A man who came upon a branch of a tree overhanging a road and decided to move if from the way of Muslims to keep it from annoying them was brought into paradise."
Anas reported God’s messenger as saying,
“If any Muslim plants something or sows seed from which man, bird, or beast eats, it counts as sadaqa for him.”
(Bukhari and Muslim.)
In a version by Muslim from Jabir it says that what is stolen from it counts as sadaqa for him.