Jolie Lee

USA TODAY Network

Adultery isn't just a crime in the eyes of your spouse. In 21 states, cheating in a marriage is against the law, punishable by a fine or even jail time.

The New Hampshire Legislature is voting on a law Thursday that would repeal its anti-adultery law. Currently, adultery is a Class B misdemeanor and punishable by a fine up to $1,200 in the state.

"I don't think there's any appetite in New Hampshire to use police powers to enforce a marriage," New Hampshire state Rep. Tim O'Flaherty, the bill's sponsor, said during a public hearing last month.

■ Graphic: States with anti-adultery laws include Michigan

Last year, Colorado repealed its anti-adultery law.

States' anti-adultery laws are rarely enforced, a vestige of our country's Puritanical beginnings, says Naomi Cahn, a law professor at the George Washington University Law School.

"I suspect it's not something most people having non-marital relationships are thinking about," Cahn tells USA TODAY Network.

■ Related: Adultery site is big in Japan

States with anti-cheating laws generally define adultery as a married person having sexual intercourse with someone other than their spouse. In North Carolina, adultery is when two people "lewdly and lasciviously associate." In South Carolina, adultery includes having "habitual carnal intercourse" with a person who is married to someone else.

In practical terms, committing adultery poses very little threat of prosecution, but it could have civil consequences, such as impacting custody battles during a divorce, says Melissa Murray, law professor at the University of California-Berkeley.

"There's a stigma attached to adultery," Murray tells USA TODAY Network. "The fact it is a crime maintains that stigma."

Cheating on your spouse can even be grounds for losing your job. This is particularly true in the military, where adultery has a maximum punishment of a dishonorable discharge and confinement for one year, according to the Uniform Code of Military Justice. In the past eight years, 30% of the commanders fired lost their jobs due to sexual misconduct, including adultery, the Associated Press reports.

Although adultery is a misdemeanor in most of the states with laws against it, some — including Michigan and Wisconsin — categorize the offense as a felony.

Punishments vary widely by state. In Maryland, the penalty is a paltry $10 fine. But in Massachusetts, an adulterer could face up to three years in jail.

In 2003, the Supreme Court ruled in Lawrence v. Texas that sexual activity between consenting adults is legal, and state laws banning homosexual sodomy are unconstitutional.

Whether the Lawrence case applies to anti-adultery laws remains "an open question," Murray says, and the continued existence of these laws "raise very important privacy issues."

Follow @JolieLeeDC on Twitter