The Cheesecake Factory and a janitorial contractor have been found liable in a $4.57 million wage theft case involving hundreds of underpaid janitorial workers at eight California locations, the state's Department of Industrial Relations said on Monday, sending a strong message to businesses that they are accountable for workplace violations — even if their workers are hired by contractors.

The janitors, who worked at Cheesecake Factory restaurants in Orange and San Diego Counties, started their shifts around midnight, worked until morning without proper periods for meals or rest breaks, and were not allowed to leave until kitchen managers conducted walk-throughs to review their work, the investigation found.

The walk-throughs, which led to additional tasks, resulted in each worker logging up to 10 hours of unpaid overtime each week, the Department of Industrial Relations said.

More from the New York Times:

New York officials battle wage theft in construction industry

New weapon in day laborers' fight against wage theft: a smartphone app

More workers are claiming 'wage theft'

"We take matters of this nature very seriously," Sidney M. Greathouse, the vice president of legal services at The Cheesecake Factory Inc., said in a statement. "We are continuing to review the allegations and will respond to the wage citation within the time provided."

Lilia Garcia-Brower, executive director of the Maintenance Cooperation Trust Fund, the nonprofit that represented the Cheesecake Factory janitors, said "this type of corporate behavior reinforces the need" for laws that protect workers.

"Decision-makers," she said, need to "respond to the fact that workers are being robbed every day in their facilities and responsible employers are being undercut."

Workers in the janitorial industry are especially vulnerable to wage theft because they often work in the middle of the night in isolated settings, Julie A. Su, the California labor commissioner, said on Tuesday.

"There is this perception — that is sometimes real — that they don't know their rights, they don't have access to learn their rights and will be afraid to speak up," Ms. Su said.

The Cheesecake Factory had used the janitorial contractor Americlean Janitorial Services Corporation, which subcontracted the work to Magic Touch Commercial Cleaning, the company that managed the 559 underpaid workers.

Magic Touch is based in San Diego, according to Erika Monterroza, a spokeswoman for the Department of Industrial Relations. It was later renamed as Z's Commercial Quality Cleaning.

"Basically it was an attempt by the owner to evade enforcement," Ms. Monterroza said.

Companies that use wage theft as a business practice "will try to get rid of the business that is under investigation and open a new business," she said. "Perhaps they will use another colleague or relative. In this case, it was the business owner herself who opened up a new business entity."

The owner of Magic Touch, Zulma Villegas, must pay the workers $3.94 million in unpaid wages, overtime and damages, the Department of Industrial Relations said, as well as $632,750 in penalties, including the failure to provide properly itemized pay stubs.

Ms. Villegas could not be reached for comment.

If Magic Touch does not pay, then the Cheesecake Factory and Americlean Janitorial Services are responsible for paying $4.2 million, Ms. Monterroza said.

Americlean Janitorial Services, which does business as Allied National Services, did not immediately respond to a request for comment.

The California labor commissioner's investigation began in 2016, after the Employee Rights Center, a nonprofit group in San Diego, reported wage theft at a couple of Cheesecake Factory locations that used workers hired by Magic Touch, Ms. Su said.

"Instead of just ending our work there, we expanded to all of the Cheesecake Factory locations that this company was cleaning for," she added.

According to the Bureau of Labor Statistics, there are about 2,384,600 janitors and building cleaners in the United States, and they earn a median hourly wage of $12.02.

But many janitorial workers are paid "way less" than minimum wage, said Victor Narro, project director at the U.C.L.A. Labor Center. In California, the state minimum wage is $11.00 an hour for businesses with 26 or more employees.

"These industries are for the most part cash industries," he added, which makes it hard to document wages.

Wage theft is especially problematic in California, experts say. A 2010 study found that violation rates of basic laws mandating a minimum wage and overtime pay were higher in Los Angeles than in New York City or Chicago.

Subcontracting is part of the problem.

"When you're subcontracting the work force, it's very hard to find the chain of liability," Mr. Narro said. "These janitors sometimes don't even know who their employers are."

But two recent laws make it more difficult for California employers to avoid responsibility for the contractors they hire.

A law signed by Gov. Jerry Brown that took effect in 2015 holds employers accountable for workplace violations originating from their contractor. And another law, which went into effect in 2016, says in part that businesses that contract for services in the property services industry, which includes janitorial work, will be jointly liable for any unpaid wages, including interest.

"It's going to be a lot easier to go after these kinds of businesses than in the past," Mr. Narro said. "This is only in California, but my hope is that other states follow a similar path."