Such of your women as commit indecency, call four of you to witness against them; and if they witness, then detain them in their houses until death takes them or God appoints for them a way. 15 And as for those twain of you who commit it, hurt them both; then, if they repent and amend, turn away from them; verily Allah is Relenting, Merciful. 16 God shall turn only towards those who do evil in ignorance, then shortly repent; God will return towards those; God is All-knowing, All-wise. 17 But of no avail is repentance of those who do evil until death approaches any one of them and then he says: 'Now I repent.' Nor is the repentance of those who die in the state of unbelief of any avail to them. For them We have kept in readiness a painful chastisement. 18 Believers, it is unlawful for you to inherit women forcefully, neither bar them, in order that you go off with part of what you have given them, except when they commit a clear indecency. Live with them honorably. If you hate them, it may be that you hate something which Allah has set in it much good. 19 And if you wish to change one wife for another and you have given her heaps of treasure, do not take back anything from it; will you take it back by slander and open sin? 20 How shall you take it, when each of you has been privily with the other, and they have taken from you a solemn compact? 21 And do not marry those [women] whom your fathers married, except what has already occurred. Indeed, it was an immorality and hateful [to Allah] and was evil as a way. 22