The Prophet ﷺ said that an ant once bit one of the prophets, so he ordered the ants' nest to be burned, and it was burned. Then Allah revealed to him, "A single ant bit you, and you have destroyed a whole community that was glorifying Me?"
أخبرنا إسحق بن إبراهيم قال حدثنا معاذ بن هشام قال حدثني أبي عن قتادة عن الحسن عن أبي هريرة نحوه ولم يرفعه
[Sahih] Previously mentioned before this one, and it is in Al-Kubra, hadith no. 4873. It was also narrated by Habib bin Shaheed and Salama bin Alqama, from Muhammad bin Sirin, from Abu Hurairah, with the same wording, but as a mawquf report. Both routes, the marfu and the mawquf, are sahih, and Allah knows best.