More than a decade ago, Los Angeles stopped putting people in jail for sleeping in the streets — a compromise laid out in a court settlement that halted police enforcement of laws barring encampments in public spaces until the city could build more housing for homeless people.

That 2007 settlement, commonly known as the Jones agreement, came the year after a ruling from the U.S. 9th Circuit Court of Appeals that found L.A.’s sweeps of homeless encampments on skid row were cruel and unusual punishment. Last September, in a case from Boise, Idaho, the same court issued a similar ruling, saying that prosecuting people for sleeping on the sidewalk when there are not enough shelter beds or housing was unconstitutional.

The latter decision turned what was supposed to be a stopgap arrangement in L.A. into a sweeping and potentially open-ended curb on police powers in nine Western states, including in California, where an affordable housing shortage and an explosion of homelessness have made providing sufficient shelter a tough — if not impossible — proposition.

Now, Theodore B. Olson, a conservative legal hero who has argued 63 times before the U.S. Supreme Court, has launched an appeal that could restore L.A.’s authority to clear street encampments at night — and reverse the city’s gradual shift toward decriminalizing homelessness and liberalizing its policies.

This month, the U.S. Supreme Court granted Olson and fellow attorney Theane Evangelis an extension to ask the justices to take up the case, Martin vs. City of Boise — the first step in an appeal.

The attorneys, both with Gibson, Dunn & Crutcher, a powerhouse law firm with offices in L.A., cited the “urgent crisis and the public health challenge” of burgeoning encampments. They argue the shantytowns trap homeless people in dangerous conditions that keep them from seeking shelter and services.

Eric Tars, legal director of the National Law Center on Homelessness & Poverty, said it was “disingenuous” to argue that cities can’t help people in camps or that homeless people won’t use shelters if they are clean, safe and available.

Tars — who, working with another big law firm, Latham & Watkins, and Idaho Legal Aid Services, brought the Boise case to the 9th Circuit on behalf of six homeless individuals — said punishing homeless people for sleeping outdoors saddles them with arrest records and tickets they can’t pay that keep them from getting jobs and housing.

Evangelis, whose Los Angeles office is only blocks from downtown street encampments, said that, like most Angelenos, she had followed news on the homeless issue “with interest” before deciding that the case merited the court’s attention.

“This is an important case that warrants Supreme Court review,” she said, “and I reached out to the city [of Boise] and offered our assistance.”

Mike Journee, a spokesman for Boise, said several law firms approached the city offering to file an appeal. But Gibson, Dunn & Crutcher put forward a “great deal” — a flat fee of about $300,000, which is far below the firm’s usual rates. The attorneys also demonstrated interest and experience in the subject matter, he said.

The high court typically takes only 70 of 9,000 appeal requests a year, said Erwin Chemerinsky, dean of law at UC Berkeley. And it’s unclear whether the justices will hear this case.

In April, the 9th U.S. Circuit Court of Appeals refused to reconsider the Boise ruling. But in an unusual dissent, Judge Milan D. Smith Jr. said the opinion broke with precedent for the U.S. Supreme Court and other appellate courts — a clear invitation to the high court to step in, legal experts said.

Olson, who served as solicitor general under President George W. Bush, brings decades of experience before the court, as well as sterling conservative and legal credentials that match those of a majority of the high court’s justices.

In Bush vs. Gore, he persuaded the justices to drop a 2000 recount of ballots in Florida, putting the Republican candidate in the White House. In one of the cases involving Citizens United in 2010, he helped strike down special interest campaign financing limits and spoke out against former President Clinton and Hillary Clinton.

More recently, with attorney David Boies, he led the battle to overturn Proposition 8, which in 2008 banned same-sex marriage in California, upsetting some of his conservative allies.

Evangelis briefly advised the Central City Assn. this year on a matter related to homelessness. But Jessica Lall, chief executive of the downtown Los Angeles business group, which generally supports curbing encampments, said it is not financing or taking part in the appeal.

Chemerinsky, who also is a prominent constitutional scholar, said he doubts the Supreme Court will take up the Boise case.

“The 9th Circuit got it right,” he said. “A city can’t make it a crime to be a homeless person.”

In his dissent, Smith, who was joined by five judges on the 9th Circuit, said that the Boise ruling had begun “wreaking havoc” on local government and predicted that it would lead to dropping laws against public defecation and urination and force cities into ruinous investments in shelters or housing.

Smith put a photograph of sidewalk tents on a downtown Los Angeles street into the record, asserting that the Boise decision “shackles the hands of public officials trying to redress the serious societal concern of homelessness.”

Judge Marsha S. Berzon, who wrote the original decision in the case, objected to Smith’s inclusion of the photo as outside the scope of the case and said his dissent was a “distorted presentation of the issues.” She called the ruling “narrow” and said the court wasn’t telling cities how to deal with their camps but rather to stop prosecuting unsheltered people who have no alternatives.

Since the Jones settlement in 2007, the spread of encampments has pushed homelessness to the top of L.A.’s political agenda, driving cleanup costs above $40 million a year and drawing officials into fractious debates over hygiene and public health as well as legal disputes over confiscating and destroying homeless people’s property.

In June, several Los Angeles city councilmen accused neighboring suburbs of pushing homeless camps into their jurisdiction, and city sanitation officials laid out a plan to overhaul the way the city cleans up the camps.

To get out of the Jones settlement, Chemerinsky said, Los Angeles would still have to show it has built the requisite housing, split between downtown and the rest of the city. Advocates already are lining up to dispute that new housing the city has already built fits the bill.

Tars said some cities, including Modesto, are responding constructively to the Boise decision, opening shelters and designated areas for homeless people to camp.

“It’s not a perfect option, but for a place like L.A., it may be necessary as an interim step,” he said.

The petition to the U.S. Supreme Court is due Aug. 29, with a decision from the court on whether to hear the appeal expected no sooner than October, according to the city of Boise.