The House of Representatives voted overwhelmingly Tuesday to change a foundational internet law to empower prosecutors and sex trafficking victims to punish online platforms that facilitate their exploitation.

The reform, adopted in a 308-107 vote as an amendment to a larger anti-sex-trafficking bill, would add a carve-out to Section 230 of the Communications Decency Act of 1996, which gives legal immunity to websites hosting third-party content.

The amendment from Rep. Mimi Walters, R-Calif., removes immunity for web platforms if the site operators are allegedly violating a state law against “promotion or facilitation of prostitution.”

The underlying Allow States and Victims to Fight Online Sex Trafficking Act ( FOSTA) passed as well.

Proponents said the reform would allow victims to hold accountable services like Backpage.com that host personal ads including those of alleged trafficking victims, and would allow state prosecutors to go after the facilitators without being preempted by the federal law.

Critics of the amendment warn that changing the law risks crushing online entrepreneurship and that it was written in such a way that could backfire.

Rep. Zoe Lofgren, D-Calif., urged colleagues to resist the reform, saying the amendment may result in website moderators choosing not to moderate any content to avoid liability for allegedly facilitating sex trafficking.

The Electronic Frontier Foundation advocacy group warned that the underlying law also creates a new federal trafficking crime that “would not require a platform to have knowledge that people are using it for sex trafficking purposes.”

“Facing the threat of extreme criminal and civil penalties, web platforms large and small would have little choice but to silence legitimate voices,” EFF warned. “Platforms would have to take extreme measures to remove a wide range of postings, especially those related to sex.”

Consumer Technology Association president Gary Shapiro warned in the runup to the vote that the trade group “is concerned that this needlessly rushed and unorthodox process will result in unintended language gravely harming legitimate businesses and the internet economy.”

The reform faces an uncertain fate in the Senate, a similar measure has bipartisan backing but where it is strongly opposed by Sen. Ron Wyden, D-Ore.

Opponents of sex trafficking, however, cheered the long-sought change.

"We are thrilled that on both sides of the aisle, lawmakers are putting people above profits and understanding the need to update a law that until now has protected sites that allow women and children to be sold online for sex right here in our country,” said Lauren Hersh, national director of World Without Exploitation. “Today's vote sends a clear a message that the internet is no longer a safe haven for sex traffickers and those who profit from them. We are incredibly grateful to Reps. Wagner and Walters, along with Carolyn Maloney and Kevin McCarthy, who have been truly inspirational in making meaningful change in the fight to end human trafficking in our country.”