Supporters of gay marriage wave the rainbow flag after the U.S. Supreme Court ruled on Friday that the U.S. Constitution provides same-sex couples the right to marry
Supporters of gay marriage wave the rainbow flag after the U.S. Supreme Court ruled that the U.S. Constitution provides same-sex couples the right to marry at the court building in Washington June 26, 2015. Reuters

The U.S. House of Representatives on Thursday was poised to give final congressional approval to legislation that would ensure federal recognition of same-sex marriages, a measure born out of concern that the Supreme Court could reverse its support for such nuptials.

Following the expected House passage, the measure would go to Democratic President Joe Biden's desk for signature into law. The Respect for Marriage Act, as it is called, won Senate approval last month.

The legislation is narrowly written to act as a limited backstop for the 2015 Supreme Court decision that legalized same-sex marriage nationwide, known as Obergefell v. Hodges. It would allow the federal government and states to recognize same-sex and interracial marriages as long as they were legal in the states where they were performed. It specifically makes concessions for religious groups and institutions that do not support such marriages.

But the legislation would not bar states from blocking same-sex or interracial marriages if the Supreme Court allowed them to do so.

When the Senate passed it by a vote of 61-36, 12 Republicans joined 49 Democrats in supporting it, but most of the chamber's Republicans voted against it.

The legislation was written by a group of Democratic and Republican senators in response to fears that the Supreme Court, with its increasingly assertive conservative majority, could someday strike down the Obergefell ruling, potentially jeopardizing same-sex marriage nationwide. The court has shown a willingness to reverse its own precedents as it did in June when it overturned its landmark 1973 ruling that had legalized abortion nationwide.

A broader version of the bill - without the explicit protections for religious liberty - passed the 435-seat House in August, with the backing of all the Democrats and 47 Republicans. Most House Republicans voted against it. But to get the necessary 60 votes in the Senate to proceed with the legislation amid opposition by many Republican senators, its co-sponsors added an amendment clarifying that religious groups could not be sued under the it.

Democrats cheered the bill's Senate passage as a civil rights victory for LGBT rights at a time when some states have pursued measures aimed at limiting the rights of transgender people. Republican supporters hailed its affirmation of protections for religious groups who disagree with a majority of the country.

About 568,000 married same-sex couples live in the United States, according to the U.S. Census Bureau.