Uber and Postmates filed a lawsuit in federal court in California on Monday, seeking an injunction to prevent the state’s landmark freelancer law from taking effect against them on Jan. 1 as scheduled.

The action underlines how high the stakes are for Uber and Postmates with the new California law, called Assembly Bill 5. The law could potentially threaten their businesses because under it, workers must be classified as employees rather than contractors under certain conditions, such as if a company controls how they do their work or if the work is a regular part of the company’s business.

Most employment experts have said the new law will require Uber and its rival, Lyft, along with delivery services like Postmates, to classify their drivers in California as employees. That could add 20 to 30 percent to Uber’s and Lyft’s labor costs and lead to many hundreds of millions of dollars in additional expenses a year, if not more.

As employees, drivers would be protected by minimum wage and overtime rules and would be eligible for workers’ compensation and unemployment insurance. The companies would have to pay half of their payroll taxes for Medicare and Social Security.