The federal Defense of Marriage Act (DOMA) (Pub.L. 104-199, 110 Stat. 2419, previously codified at 1 U.S.C. § 7, 28 U.S.C. § 1738C) was a federal law that (1) allowed states to refuse to recognize same-sex marriages entered into in other states (Act § 2), and (2) defined "marriage," for purposes of federal law, as the union of one man and one woman (Act § 3). Under DOMA, the federal government was able to deny same-sex married couples any of the federal benefits opposite-sex married couples received.
In United States v. Windsor, 570 U.S. 744 (2013), the U.S. Supreme Court ruled that DOMA § 3 violated the Fifth Amendment Due Process Clause and was unconstitutional. As a result, same-sex marriages were recognized by the federal government and qualified for federal benefits, including immigration status, Social Security benefits, and federal tax benefits.
In Obergefell v. Hodges, 576 U.S. 644 (2015), the U.S. Supreme Court ruled that the Fourteenth Amendment Due Process Clause and Equal Protection Clause guaranteed the fundamental right to marry to same-sex couples on the same terms as were guaranteed to opposite-sex couples. Obergefell struck down DOMA § 2 and effectively requires that all 50 states and the District of Columbia recognize same-sex marriages just as they do opposite-sex marriages.
The federal Respect for Marriage Act (RFMA) (1 U.S.C. § 7, 28 U.S.C. § 1738C), which became law on December 13, 2022, repealed DOMA.
Many states have passed what are often referred to as "defense of marriage" laws. Generally speaking, these laws are designed to refuse recognition of same-sex marriages. Obergefell rendered them unconstitutional to the extent they purport to ban the performance or recognition of same-sex marriages.