Imam al-Zuhri narrates from Sahl bin Sa'd (may Allah be pleased with him) that a man came to the Messenger of Allah (peace and blessings be upon him) and said: O Messenger of Allah (peace and blessings be upon him)! What is your view about a man who sees another man with his wife: should he kill him, and then you would kill him (in retaliation)? Or what should he do? Allah, the Lord of Might, revealed the ruling in the Qur'an concerning those who perform li'an. The Messenger of Allah (peace and blessings be upon him) said: "Allah has passed judgment concerning you and your wife." Sahl (may Allah be pleased with him) says: I was present with the Messenger of Allah (peace and blessings be upon him) when the two of them performed li'an. Uwaymir (may Allah be pleased with him) said: If I keep her as my wife, then I have lied against her. He separated from her, and the sunnah too is this: the two who perform li'an are to be separated. The woman was pregnant; the husband denied the pregnancy; the child was attributed to his mother, and the mother and son will inherit from each other the shares Allah has set for them in inheritance. Abu Ya'la says: "Judgment has been made concerning you." Abu Ya'la and al-Hasan say: He said: O Messenger of Allah! If I keep her as my wife. And the two of them said: So it became a sunnah among them; and in everything else their narration is the same.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب اللعان / 15321