Abdullah bin Umar reported,

The Messenger of Allah ﷺ said, "A woman was punished because of a cat she had confined until it died, and she entered the Fire on account of it. She neither fed it nor gave it water while she kept it locked up, nor did she let it go free to eat from the creatures of the earth."

Azami 14816

Sahih

عن عبد الله بن عمر

أن رسول الله ﷺ قال: عذبت امرأة في هرة سجنتها حتى ماتت فدخلت فيها النار، لا هي أطعمتها ولا سقتها، إذ حبستها، ولا هى تركتها تأكل من خشاش الأرض.

الأعظمي 14816صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Superior moral conduct
Chapter
Kindness to animals
Section
Discouragement from torturing animals that do not cause harm
Numbering
Jami al-Kamil 14816 (2nd edition)