Surah An-Nisa 4:79
مَّآ أَصَابَكَ مِنْ حَسَنَةٍ فَمِنَ ٱللَّهِ ۖ وَمَآ أَصَابَكَ مِن سَيِّئَةٍ فَمِن نَّفْسِكَ ۚ وَأَرْسَلْنَـٰكَ لِلنَّاسِ رَسُولًا ۚ وَكَفَىٰ بِٱللَّهِ شَهِيدًا
What comes to you of good is from Allāh, but what comes to you of evil, [O man], is from yourself. And We have sent you, [O Muḥammad], to the people as a messenger, and sufficient is Allāh as Witness.
Translation: Saheeh International
Tafsir
Whatever good hasana means khayr befalls you O man it is from God it has come to you from His bounty; whatever evil misfortune befalls you is from yourself it has come to you as a necessary consequence of sins you have committed. …
Excerpt from Tafsir al-Jalalayn, commentary on 4:79, via Quran.com. The reader has the full commentary and 9 more tafsirs.