An Arizona sheriff known for crackdowns on people living in the country without papers is giving up his last major foothold in immigration enforcement efforts that won him popularity among voters but were gradually reined in by Washington and the courts.

Maricopa County Sheriff Joe Arpaio’s office revealed late Wednesday that it was agreeing to disband a controversial squad that has raided businesses to arrest more than 700 migrants who were charged with using fake or stolen IDs to get jobs.

“He has proved that when he gets involved in immigration enforcement, he tramples on the US constitution, at great expense to taxpayers and public safety,” said Cecillia Wang, an American Civil Liberties Union lawyer who won a racial profiling case against Arpaio’s office.

The revelation that Arpaio was voluntarily closing his criminal employment squad comes after the sheriff’s office was stripped of special federal immigration powers, found to have racially profiled Latinos in traffic stops, and investigated by federal authorities for alleged civil rights violations. The courts also have thrown out many of Arizona’s immigration laws.

Arpaio still retains limited power to confront illegal immigration, including through a civil law that imposes business-license punishments on employers who knowingly hire migrants in the country illegally.

The sheriff’s office didn’t respond to a request Thursday to interview Arpaio. But it issued a statement saying the squad will be disbanded early next year, and that grant money used in the enforcement of the ID theft laws will be returned to the state.

The sheriff’s road to immigration enforcement began in 2005 as voter frustrations grew over the state’s status as the then-busiest in migrant smuggling, and state lawmakers started responding to voters’ complaints about Arizona’s porous border with Mexico.

Like other local police bosses, Arpaio had previously left immigration enforcement to federal authorities.

He explained his decision to enter immigration enforcement as addressing a public safety concern. And he eventually set up squads that focused on migrant smuggling and businesses that hired migrants.

“We don’t go after the addicts on the street,” Arpaio said in a 2005 interview about his newly formed smuggling squad, likening his immigration crackdown with his approach to investigating drug cases. “We go after the peddlers. Same philosophy.”

His supporters have said the sheriff was the only local police boss to do something about illegal immigration in the face of inadequate federal enforcement.

Critics, on the other hand, have said Arpaio picked on powerless migrants because it was popular with voters. They have said Arpaio focused too much on rank-and-file people and gave too little scrutiny to smugglers and employers who hired migrants in the country illegally.

Arpaio’s immigration efforts reached their peak around 2010, when he launched immigration patrols known as “sweeps”.

During those stings, deputies flooded part of a city – in some cases, heavily Latino areas – over several days to seek out traffic violators and other offenders.

Immigrants who were in the country without papers accounted for 57% of the 1,500 people arrested in the 20 sweeps conducted by his office since January 2008, according to figures provided by Arpaio’s office.

But a backlash was brewing in Washington and in the courts.

In late 2009, Washington stripped some of his deputies of their power to make federal immigration arrests.

A federal judge last year ruled Arpaio’s office systematically racially profiled Latinos in traffic and special immigration patrols. The sheriff vigorously denies the court’s conclusions.

Arpaio’s now-disbanded migrant smuggling squad recently came under scrutiny from the judge in the profiling case after allegations of misconduct surfaced this year, including suggestions a squad member was shaking down people who were in the country illegally.

The sheriff himself has been criticized by the profiling case’s judge for not embracing the changes needed to remedy constitutional problems with some of his agency’s traffic stops. The judge is moving closer to launching a contempt-of-court case against Arpaio for repeatedly disregarding orders in the profiling case.

Even though his involvement in immigration enforcement has gradually dwindled over the years, Arpaio still speaks up on the subject.

Last month, he filed a lawsuit that seeks to dismantle President Barack Obama’s executive order that lifts the threat of deportation from millions of migrants living without papers in the United States.