2:280
وَإِن كَانَ ذُو عُسْرَةٍ فَنَظِرَةٌ إِلَىٰ مَيْسَرَةٍ ۚ وَأَن تَصَدَّقُوا۟ خَيْرٌ لَّكُمْ ۖ إِن كُنتُمْ تَعْلَمُونَ
wa-in kāna dhū ʿus'ratin fanaẓiratun ilā maysaratin wa-an taṣaddaqū khayrun lakum in kuntum taʿlamūna
If the debtor is in difficulty, then delay things until matters become easier for him; still, if you were to write it off as an act of charity, that would be better for you, if only you knew.
And if the debtor is in a hard time (has no money), then grant him time till it is easy for him to repay, but if you remit it by way of charity, that is better for you if you did but know.