From Sahih Bukhari (Hadith 1057):
Narrated Abu Mas`ud:Allah's Messenger (ﷺ) said, "The sun and the moon do not eclipse because of someone's death or life but they are two signs amongst the signs of Allah, so pray whenever you see them
Reference: Bukhari 1057