Authorities battling massive wildfires in large swathes of California issued mandatory evacuation orders and health warnings Friday over the worsening air quality as the flames grew ever closer to populated areas.

After almost a month of wildfires, the National Weather Service warned that satellite images showed “widespread smoke” drifting from the fires into western and central Canada before heading back south in the US Northern Plains.

The Kaibab National Forest service in neighboring Arizona warned that “wildfires across the West are creating regional haze.”

But it was northern California where most air quality alerts were being issued, with warnings of “unhealthy conditions” for vulnerable groups such as the very young and old.

The Mendocino Complex, made of two separate blazes, has been declared the most destructive fire in the state’s history.

Its largest blaze, the Ranch Fire, was only 53 percent contained compared to 87 percent for its twin River Fire.

Further north, the Carr Fire was declared 51 percent under control, after scorching 180,000 acres (73,000 hectares) of land and claiming the lives of three firefighters and five civilians, making it California’s third deadliest fire ever.

More than 14,000 firefighters, including reinforcements from as far away as Australia and New Zealand, have fanned out across the state to stop the multitude of infernos.

Some inmates even assisted in the effort. The Miramonte jail camp made a fire line to stop the advancing Holy Fire from consuming homes in the area.

“Oh man, it’s hard, but we make it look easy,” said one of the inmates, Michael Henson. “Man, you know, we (are) just trying to get the job done. You know, us firefighters help protect the community.”

– Erratic court appearance –

The man accused of deliberately starting the latest fast-moving blaze faces life in prison if convicted of arson and other charges.

Forrest Gordon Clark, 51, stands accused of starting the Holy Fire, which in four days has burned more than 18,000 acres of Cleveland National Forest 60 miles (100 kilometers) north of San Diego. It is still spreading.

Prosecutors say Clark started the fire, which is only five percent contained, with the intention of causing damage to others and burning a forest. The blaze has razed a dozen properties so far.

He has also been charged with threatening neighbors — one of whom lost his cabin in the fire — and resisting arrest. He faces sentences ranging from 10 years to life imprisonment.

During his initial court appearance, Clark flipped his dark, waist-length hair, spat and paced back and forth behind the chain-link fence of the court cell.

“That’s a lie,” Clark interrupted the judge while charges were read. His lawyers had to intervene repeatedly to ask him to keep quiet.

At first, Clark would not show his face, his lawyers saying he feared reprisals against his family.

His lawyers asked to postpone the preliminary hearings by a week so that they could study the government’s evidence.

“May I pay for that immediately? Can I post bail? I can handle a million (dollars) right now, easily,” Clark added, but the judge refused his request.

He had refused to leave his jail cell on Thursday.

Mike Milligan, the local volunteer fire chief who owns a cabin near Clark’s, told The Orange County Register that Clark had long-running feuds with neighbors in the area.

Milligan said that Clark had recently sent him an email warning, “this place will burn.”

The head of the Orange County team fighting the Holy Fire said the blaze had started near Clark’s cabin in Jim Canyon.

Before his arrest, Clark told a reporter he had nothing to with the fire.

“I was asleep. I had two earplugs in,” he told the reporter. “I woke up and my stuff was all on fire,” he said. He also claimed he had been threatened by the MS-13 gang.

– Mass evacuations –

The blaze has already forced the evacuation of 7,400 homes and more than 21,000 people. Many schools have been forced to close, and more evacuation orders were being issued.

InciWeb, the interagency incident information management system offering updates on more than a dozen fires in the tinder-dry west of the country, said that “steep inaccessible terrain will continue to allow the fire to spread into new areas.”

High temperatures were expected to worsen conditions and “increase the likelihood of extreme fire behavior as well as heat illness issues for the firefighters and the public,” it said.

The forest service said: “We continue to actively engage, but cannot get ahead of the fire.”

California Governor Jerry Brown has declared a state of emergency for Orange and Riverside counties, where the fire is concentrated.