Sura Al-Baqara

2:224

وَلَا تَجْعَلُوا۟ ٱللَّهَ عُرْضَةًۭ لِّأَيْمَٰنِكُمْ أَن تَبَرُّوا۟ وَتَتَّقُوا۟ وَتُصْلِحُوا۟ بَيْنَ ٱلنَّاسِ ۗ وَٱللَّهُ سَمِيعٌ عَلِيمٌۭ

GÖR INTE Gud till måltavla för era eder så att ni [i Hans namn] hindrar er själva från att göra gott och frukta Gud och att medla i tvister mellan människor. Gud hör allt, vet allt.

Tafsir 2:224

Do not use the name of Allah in your oath as an excuse for not doing good e.g. being mindful of Him, being virtuous, and reconciling between people. Yet if you have taken an oath not to do any good actions, then do good actions and make a compensation for the oath. Allah hears your statements and knows your actions and will reward you for them.