This term for masturbation was widely used in 18th
Century medical books like Onania and
Tissot's L'Onanie. The term comes form
the Biblical story of an unfortunate man named Onan.
The tale of Onan is told in Genesis chapter 38.
Onan's older brother, Er, was smitten dead by God for some unspecified wickedness and left
behind a wife, but no male heir. In keeping with Hebrew custom of the time, Judah,
Er's father, ordered Onan to marry Er's widow, Tamar, and produce an heir for
Er.
Onan dutifully married Tamar but he was not happy about
it. "Onan knew that the seed should not be his [under Hebraic law, the
offspring produced would belong to Er's family line]; and it came to pass, when he went in
unto his brother's wife, that he spilled it on the ground, lest that he should give seed
unto his brother." For this, God "slew him".
While most modern theologians believe Onan's sin was his
hatred for Er, medieval and early modern clerics found the fruitless "spilling of
seed" to be his capital crime. Hence, "onanism".