Who Was Onan? The Bible's Most Misunderstood Figure
Genesis 38 has nothing to do with masturbation. It has everything to do with inheritance law.

Onan appears in four verses in Genesis 38 and is never mentioned again. His name has entered dictionaries as a synonym for masturbation. Most people who search for him are checking what the text actually says or evaluating a moral claim built on his story. The claim is that God killed Onan for wasting seed, establishing a divine prohibition on contraception and self-pleasure. The claim is almost certainly wrong. Genesis 38 is a case study in inheritance fraud, and the sin it records has a specific victim, a specific legal context, and a specific motive that the text states plainly.
The Levirate Law
The story of Onan belongs to a legal institution called levirate marriage, set out in Deuteronomy 25:5-10. When a married man died without a son, Israelite law held that his surviving brother had an obligation to marry the widow and produce an heir for him. The firstborn child of that union would be counted legally as the dead man's heir, inheriting his name and his estate.
The mechanism mattered. A brother could decline by going before the village elders and submitting to the halitzah, the removal of the sandal. The widow pulled the sandal from his foot and spat in his face; he was known from then on as the house of him who had his sandal pulled off. This ceremony was public, permanent, and shaming, but it carried no criminal punishment. The sandal removal was the formal refusal. A man who did not seek it, who proceeded to sleep with his brother's widow, had by that act accepted the role and all its obligations.
Onan did not seek the ceremony. He went to Tamar. By proceeding, he accepted the obligation publicly. He then betrayed it in private.
Genesis 38
The Genesis 38 narrative interrupts the Joseph story without warning. Joseph has just been sold into Egypt when the text cuts to his brother Judah, who marries a Canaanite woman and has three sons: Er, Onan, and Shelah.
Er, the eldest, marries a woman named Tamar. God finds Er wicked and kills him. Judah then instructs Onan: go in to your brother's wife, perform the duty of a brother-in-law, and raise up offspring for your brother.
Onan understands the calculation immediately. Any son born to Tamar would be Er's legal heir, not Onan's. Onan would bear the cost of the arrangement while the inheritance benefit went to his dead brother's line. So he goes to Tamar, accepts the role by proceeding, and then sabotages it: he withdraws before completion each time, spilling seed on the ground. He maintains the appearance of fulfilling the obligation while ensuring it never produces a result. The text states his motive in one clause: lest he should give seed to his brother. God kills him.
The chapter does not end there. Judah, now afraid that Shelah will also die, sends Tamar back to her father's house with a promise that Shelah will come to her when he is grown. He never sends Shelah. Tamar eventually disguises herself as a prostitute, Judah sleeps with her without recognizing who she is, and when her pregnancy becomes known he orders her burned for harlotry. She produces his seal and staff as proof. His judgment ends the matter: she has been more righteous than I, because I did not give her to Shelah my son.
The moral frame of Genesis 38 is about who did and did not honor the obligation owed to Tamar. Er dies. Onan accepts and then defrauds. Judah withholds Shelah indefinitely. Tamar, the only one who acted with integrity, is declared righteous. Onan is the second betrayal in a sequence of three.
The Goel
Levirate marriage overlaps with a larger Israelite legal concept: the goel, or kinsman-redeemer. The goel was the nearest male relative responsible for protecting a family member in serious distress. His duties included buying back land that a kinsman had sold under financial pressure, redeeming a relative sold into debt-slavery, and avenging the blood of a murdered kinsman. When a widow was left without an heir and the family estate was at risk, goel responsibility and levirate duty converged.
The goel role was a legal obligation, not optional charity. Land, kinship, and covenant identity were intertwined in Israelite law. A family's inherited land was not a commodity to be lost permanently through misfortune. The goel existed to prevent that loss.
To accept the role and then perform it fraudulently, as Onan did, was to corrupt the system from within while appearing to uphold it. Tamar had no knowledge she was being cheated. Judah had no knowledge his grandchild line was being denied. Onan extracted the social standing that came with accepting the role while ensuring none of its obligations were met.
Ruth 4: The Later Inversion
Ruth 4 returns to exactly this situation. The same calculation appears, made by a different man, and the Bible's contrast between the two is the interpretive point.
Naomi is a widow whose husband and both sons died abroad without heirs. Her daughter-in-law Ruth has returned with her to Bethlehem. Boaz, a kinsman of Naomi's dead husband, is willing to act as goel and marry Ruth. There is a closer relative with first right of redemption.
Boaz brings this man before the elders at the city gate. The nearer kinsman agrees to buy back Naomi's land. Then Boaz adds the detail he had held back: Ruth comes with it, and the child she bears will inherit the land in the name of her dead husband. The man withdraws immediately. I cannot redeem it for myself, he says, lest I mar my own inheritance. He submits to the sandal ceremony and walks away.
The text does not condemn him. He used the lawful opt-out. The elders witness it; the transaction is clean. This is the difference from Onan: the unnamed kinsman made the same calculation openly, before witnesses, and bore the public consequence. Onan made the same calculation secretly while proceeding as though he were fulfilling his duty. Tamar could not defend herself against a fraud she did not know was happening.
The book of Ruth also carries the goel concept toward its theological endpoint. Boaz, acting as kinsman-redeemer for a Gentile woman with no legal standing, prefigures what later biblical writers describe as Christ's role as redeemer of those who have no standing before God. The imagery moves from the city gate at Bethlehem into Paul's letters and into Revelation, where the Lamb alone is found worthy to open the sealed deed and reclaim what was lost. The goel is not incidental background. It is the legal scaffold on which biblical redemption theology is built.
How the Misreading Happened
The reading of Onan's death as a divine condemnation of non-procreative sex originates primarily with Augustine of Hippo (354-430 CE). In De Nuptiis et Concupiscentia, Augustine focused on the physical act of spilling seed as the offense in itself, extracting it from the levirate context. Clement of Alexandria had moved in this direction earlier, drawing on Stoic natural law theory to argue that the only legitimate purpose of intercourse is procreation. Once the physical act became the interpretive center, the property fraud against Tamar dropped out of view.
Medieval Catholic theologians systematized the argument. Thomas Aquinas applied natural law reasoning: because the finality of the sexual act is procreation, any act that deliberately frustrates that end is intrinsically disordered. The word onanism entered European languages as a synonym for masturbation, and Genesis 38:9 became the exegetical anchor for church condemnations of both masturbation and contraception.
The official Catholic position as it stands today rests primarily on natural law, not on the Onan text. Humanae Vitae (1968), Pope Paul VI's encyclical on birth regulation, condemned artificial contraception on the grounds that each conjugal act must remain open to the transmission of life. The Catechism of the Catholic Church addresses masturbation at section 2352, calling it intrinsically and gravely disordered, and contraception at section 2370. Both condemnations are grounded in the theology of the conjugal act rather than in Genesis 38 directly. The shift away from citing Onan as the primary proof text was in part a response to scholars, including Catholic ones, who had identified the exegetical problems with that reading.
The textual problem is consistent. The Deuteronomy opt-out ceremony proves that refusing the levirate obligation carried no divine punishment. If coitus interruptus were itself the sin, a prohibition on it should appear somewhere in the Old Testament's extensive laws governing sexual conduct. It does not. John T. Noonan Jr., the definitive historian of Catholic teaching on contraception, acknowledged that the Onan passage is inextricably bound up with the specific institution of levirate marriage. The condemnation is not portable to other contexts. Onan is not the Bible's statement on masturbation or contraception. He is a figure who accepted an obligation before witnesses, betrayed it in secret, and defrauded a specific woman of a specific legal right.