More than 800,000 Uber Technologies Inc. and Lyft Inc. drivers in California will soon be able to join a union and collectively bargain for higher pay and better working conditions under a landmark measure signed into law Friday by Democratic Gov. Gavin Newsom.

Supporters hailed the law as the largest expansion of private-sector collective bargaining rights in state history, marking a breakthrough in the yearslong standoff between organized labor and Silicon Valley.

California becomes only the second state, after Massachusetts, to grant union rights to ride-hailing drivers classified as independent contractors. Drivers in Illinois and Minnesota are pushing for similar recognition.

Newsom announced the signing during an unrelated news conference at the University of California, Berkeley, calling the measure “a step toward dignity and a say about their future” for gig workers.

The new law emerged from a September agreement between Newsom, state lawmakers, the Service Employees International Union, and ride-hailing giants Uber and Lyft. As part of the deal, Newsom also approved a separate bill backed by the companies to significantly reduce their insurance obligations for crashes involving underinsured drivers.

Lyft CEO David Risher said the insurance change could save the company roughly $200 million and potentially lower fares. Both Uber and Lyft contend California’s stringent insurance rules have kept ride prices higher than in other states. Uber estimates nearly one-third of each fare goes toward state-mandated coverage.

The new collective bargaining law allows drivers to unionize while maintaining their status as independent contractors — a classification that exempts the companies from providing benefits such as overtime pay, sick leave, and unemployment insurance. The legislation requires ride-hailing firms to negotiate in good faith but does not extend to delivery drivers for apps such as DoorDash.

The insurance measure cuts the required coverage for crashes caused by uninsured or underinsured motorists from $1 million to $60,000 per individual and $300,000 per accident.

“Together, these bills represent a compromise that lowers costs for riders while creating stronger voices for drivers — showing how industry, labor, and lawmakers can work together to deliver real solutions,” Ramona Prieto, Uber’s head of public policy for California, said in a statement.

Still, some drivers and labor advocates say the law doesn’t go far enough. Rideshare Drivers United, a Los Angeles-based group representing 20,000 drivers, criticized the legislation for lacking transparency requirements on driver pay.

Others welcomed the law as a long-overdue safeguard against arbitrary firings and unfair treatment by the companies.