The House on Friday passed a sweeping LGBTQ nondiscrimination bill that would modify existing civil rights legislation to ban discrimination based on sexual orientation and gender identity in employment, housing, public accommodations, jury service, education, federal programs and credit.

“The LGBTQ community has waited nearly 250 years for full equality in our country,” said Rep. David Cicilline, D-R.I., the legislation’s chief sponsor and one of eight openly LGBTQ members in the House. “Today, we’re one step closer to that goal.”

The Equality Act, which was reintroduced in March by congressional Democrats, passed by a 236-173 vote, with eight Republicans voting for it. The measure has been a priority for Speaker Nancy Pelosi, D-Calif., who said it would help bring the country closer to “full equality.”

Rep. Jimmy Gomez, D-Calif., voted for the bill, saying he had his brother and his brother's husband in mind while doing so.

"For far too long, our government has failed to provide our LGBTQ constituents with the civil rights and federal protections they need and deserve," he said in a statement. "But now, with the passage of this historic legislation, we can finally help our communities heal from the wounds inflicted by those who turned a blind eye to their oppression."

Republicans who opposed the bill, like Rep. Vicki Hartzler of Missouri, said it would jeopardize religious freedom by requiring acceptance of a particular ideology about sexuality and sexual identity. Before the vote Friday, Hartzler said the act would create "a brave new world of 'discrimination' based on undefined terms of sexual orientation and gender identity.”

A similar bill in the Senate has been co-sponsored by all Democrats except one — Joe Manchin of West Virginia — but faces long odds in the Republican-controlled chamber.

The Trump administration opposes the Equality Act, saying the bill "in its current form is filled with poison pills that threaten to undermine parental and conscience rights.”

In the absence of a national law, at least 20 states have enacted LGBTQ discrimination protections. Residents of those states enjoy many of the Equality Act's protections, but those stop at state borders. An openly LGBTQ person driving from Colorado into Nebraska would find that their right to keep their job, to keep their home, and to freely engage in commerce evaporates as soon as they cross the state line.

FOLLOW NBC OUT ON TWITTER, FACEBOOK & INSTAGRAM