California was the first state to challenge tech companies such as Uber and Lyft with bold laws meant to reshape the gig economy by converting workers into employees.

And now a handful of other states are following its lead.

Legislators in three other states with Democratic majorities, New York, New Jersey and Illinois, are considering similar bills that could open the door for a wide range of freelance workers. The bills would benefit not just app gig workers but janitors, construction workers, truckers and educational workers.

Advocates say the bills would crack down on a culture of rampant misclassification fostered by companies whose business model depends on apps like Uber, Lyft and DoorDash. Business interests who oppose the moves say they could harm the flexibility that apps give to workers, which has allowed the gig economy to flourish.

The bills show how momentum is building for long-neglected economic issues at the state level, as the debate around inequality focuses on the status of American workers. And the efforts demonstrate an increasing willingness by legislators to rein in some of Silicon Valley’s most talked about companies after years of inaction.

If they become state law, they could affect hundreds of thousands of workers, giving them access to protections like workers’ compensation, unemployment insurance, overtime and the ability to organize.

“It’s a moment in our politics, where people are understanding, especially in progressive states, these tensions between big corporations and corporate money and ordinary people,” Terri Gerstein, the director of the State and Local Enforcement Project at Harvard Law School. “These work issues and issues of economic inequality have come to such a fever pitch.”

The bills seek to target what labor experts say has been a growing problem for years: companies hiring workers as independent contractors instead of employees, which cost more. All of the bills seek to better define the line between independent contracting and steadier employment.

In New York, two efforts are underway. One would emulate California’s law by creating a strict “ABC” test, which would define workers as employees unless they are A) free from the control and direction of the company; B) engage in work outside the company’s main business; and C) already work independently from the company, doing the same kinds of thing as the company.

The other bill is similar to proposals made by Uber and Lyft in California: to create a third category called a “dependent worker” who would be neither employee nor contractor but could, at the discretion of state regulators, be granted some similar rights.

“We don’t want to see a regression in worker wages and benefits over time as the gig economy continues to expand and grow,” said Sen. Jessica Ramos, chairwoman of the New York Senate’s Labor Committee, where the bills will be considered. “I would just say that all of these app companies, especially, should come to terms with and be aware that we are looking to hold them accountable as employers.”

Ramos said she hopes one of the bills passes her committee by the end of the legislative session in June.

New Jersey has had an ABC test for workers on the books since the 1930s, but it’s just a rule, not a law. Democratic lawmakers say that codifying it into law will make it harder for future administrations to undo while increasing the pressure to enforce it. State Senate President Steve Sweeney, a Democrat, said through a spokesman that he hopes the statehouse will pass the bill by the end of the year.

That proposal comes on the heels of a report by Gov. Phil Murphy’s office that examined the issue of misclassification, noting its prevalence in labor-intensive but low-wage sectors such as construction, home care, transportation, trucking and delivery services. It cited studies estimating that as many as a third of employers misclassify at least one employee as a contractor and estimated that New Jersey loses tens of millions of dollars every year in unemployment and disability contributions as well as income taxes.

In Illinois, legislative efforts are in the beginning stages. Will Guzzardi, a Democratic representative in that state’s legislature, said he plans to introduce similar legislation this year after consulting with labor advocates and workers. He said he did not yet know whether the bill would seek to create a new class of worker or tighten restrictions on contractors as California does.

“When we’re not the first state to act, we get to reflect on the lessons of other states,” Guzzardi said.

Indeed, representatives in each of these states said they were paying close attention to California’s rollout of the law, called AB5, which has been marked by drama.

Tech companies are sponsoring a $110 million ballot initiative to exempt themselves from it, while most have been arguing that its provisions don’t apply to them in the meantime. Pro and con op-eds appear in California newspapers seemingly every day.

And certain classes of workers — freelance writers, for example, and some translators — have been particularly vocal about what they say is a threat to their livelihoods. To be able to keep freelancing, writers were capped at 35 submissions a year — a small and seemingly arbitrary number.

Lawmakers and labor advocates in other states say they are not deterred by the problems in California and hope to learn from the experience to better craft their own bills.

“It was the first in the country to do it this way,” Mario Cilento, the president of the AFL-CIO in New York, said of the intense debate around the law in California. The AFL-CIO has been closely involved with the effort in New York. “But, a lot of the pushback, most of the pushback, is coming from the app-based companies.”

And states that are crafting related bills are trying to learn from some of the unintended consequences in California, such as the outcry among writers, and lawsuits from groups such as truckers.

In New York, state lawmakers may consider allowing freelance writers and photographers far more freelance pieces before they must be converted into employees, according to an official involved in discussions on the bill.

It’s early in the legislative process, but Uber, Lyft and other gig companies could begin funding an effort to combat similar laws in other states.

In New York City, Uber aggressively beat back a separate effort to regulate its platform in 2015, when Mayor Bill de Blasio tried to cap the number of Uber vehicles in the city. Uber’s public campaign included the creation of a fake feature on its app labeled “DE BLASIO,” which sought to turn users against the plan with messages like “NO CARS-SEE WHY” and “SEE WHAT HAPPENS.” De Blasio later backed away from the proposal.

Uber has helped fund a driver’s group in New York, the Independent Drivers Guild, which was one of many groups brought in to consult on the bill to create a third category of worker, according to Barbara O’Neill, an adviser to the senator, Diane Savino, who proposed it.

“As we have already seen in California, an AB5 model can come with many negative unintended consequences, including limiting or eliminating opportunities for independent workers across a wide spectrum of industries,” Uber spokesman Matt Wing said in a statement. “A far better alternative would be to create and expand protections for independent workers, while preserving the flexibility they value.”

Read more: