The Quran mentions the gathering of animals, and a hadith reminds us that divine justice extends to them. These texts invite us to look upon every creature with respect.
A hornless ewe and a horned ewe: it is through this image that the Prophet Muhammad ﷺ illustrated the scope of divine justice. In a hadith related by Sahih Muslim, he teaches that rights will be restored to those who deserve them, until justice is done for the hornless ewe against the one that has horns. Even among animals, nothing escapes the justice of God.
Creatures gathered before their Lord
The Quran also invites us to consider the place of animals in creation. In Surah Al-An‘am, it mentions the beasts that live on earth and the birds that fly on their wings: they too form communities. The passage then states that they will be gathered before their Lord. Thus, animals are not forgotten in the Quranic account of the return to God.
Surah At-Takwir also mentions the gathering of wild beasts among the events linked to the end of time:
﴿ وَإِذَا الْوُحُوشُ حُشِرَتْ ﴾
And when the wild beasts are gathered.
(Surah At-Takwir, verse 5)
These passages address part of the question: the texts do speak of a gathering of animals. The hadith of the ewe, related by Sahih Muslim, also shows that God's justice concerns them. Yet it is not necessary to imagine, beyond what these texts say, every detail of their fate. The Quran and the hadith give us here a teaching on gathering and justice; in these passages, they do not describe a destiny identical to that of human beings.
An invitation to mercy
The Islamic tradition also recalls the value of kindness toward animals in this present life. In an account related by Sahih al-Bukhari and Sahih Muslim, a man gives water to a thirsty dog. God forgives him for this act. On this occasion, the Prophet Muhammad ﷺ teaches that there is a reward for doing good to every living being. An act as simple as giving water can thus have great significance.
These teachings invite us not to treat animals as beings of no importance. Since God knows His creatures and His justice concerns them, let us care for those we encounter: offering them water, meeting their needs and avoiding harming them are all acts of kindness within our reach.