The Obama administration has begun a profound shift in its enforcement of the nation’s immigration laws, aiming to hasten the integration of long-term illegal immigrants into society rather than targeting them for deportation, according to documents and federal officials.

In recent months, the Department of Homeland Security has taken steps to ensure that the majority of the United States’ 11.3 million undocumented immigrants can stay in this country, with agents narrowing enforcement efforts to three groups of illegal migrants: convicted criminals, terrorism threats or those who recently crossed the border.

While public attention has been focused on the court fight over President Obama’s highly publicized executive action on immigration, DHS has with little fanfare been training thousands of immigration agents nationwide to carry out new policies on everyday enforcement.

The legal battle centers on the constitutionality of a program that would officially shield as many as 5 million eligible illegal immigrants from deportation, mainly parents of children who are U.S. citizens and legal permanent residents. A federal judge put the program, known by the acronym DAPA, on hold in February after 26 states sued.

But the shift in DHS’s enforcement priorities, which are separate from the DAPA program and have not been challenged in court, could prove even more far-reaching.

The new policies direct agents to focus on the three prioritygroups and leave virtually everyone else alone. Demographic data shows that the typical undocumented immigrant has lived in the United States for a decade or more and has established strong community ties.

Although the new measures do not grant illegal immigrants a path to citizenship, their day-to-day lives could be changed in countless ways. Now, for instance, undocumented migrants say they are so afraid to interact with police, for fear of being deported, that they won’t report crimes and often limit their driving to avoid possible traffic stops. The new policies, if carried out on the ground, could dispel such fears, advocates for immigrants say.

In describing the initiatives, Homeland Security Secretary Jeh Johnson has echoed the language often used by advocates of comprehensive immigration reform, which is stalled on Capitol Hill.

“We are making it clear that we should not expend our limited resources on deporting those who have been here for years, have committed no serious crimes and have, in effect, become integrated members of our society,” Johnson said in a recent speech in Houston. He added: “These people are here, they live among us, and they are not going away.”

Since the new policies took effect in January, Johnson’s instructions have been conveyed to agents throughout the department. “We decided we’re going to draw a clear line between individuals who now have significant equities in the country versus those who are recent entrants,” said one department official, who spoke on the condition of anonymity to describe internal deliberations.

“If people are not an enforcement priority,” the official said, “. . . bottom line, the secretary has said don’t go after them.”

Broken promises

The United States’ massive dragnet is shrinking rapidly, because of the new enforcement policies and declining flows of new immigrants crossing the southwest border, DHS officials say.

Deportations, for example, are dropping. The Obama administration is on pace to remove 229,000 people from the country this year, a 27 percent fall from last year and nearly 50 percent less than the all-time high in 2012.

Fewer people are also in the pipeline for deportation. The number of occupied beds at immigration detention facilities, which house people arrested for immigration violations, has dropped nearly 20 percent this year.

And on Johnson’s orders, officials are reviewing the entire immigrant detainee population — and each of the 400,000 cases in the nation’s clogged immigration courts — to weed out those who don’t meet the new priorities. About 3,000 people have been released from custody or had their immigration cases dropped, DHS officials said.

“It does have the potential to be extremely significant. It would allow people to live without that noose over their heads of the threat of deportation at all times,’’ said Marielena Hincapié, executive director of the National Immigration Law Center, referring to the policy shift.

But Hincapié and other advocates — who have long clashed with the administration over its aggressive enforcement — said there is widespread skepticism in the immigrant community about whether agents on the ground will adjust their activities to match the new priorities.

“It all sounds great, but it means nothing if it’s not applied,” said Kica Matos, director of immigrant rights and racial justice at the Washington-based Center for Community Change. She faulted U.S. Immigration and Customs Enforcement (ICE), part of DHS, for what she said has been a series of broken promises to more humanely enforce immigration laws.

“DHS is an agency that has terrorized our community for a really long time,” Matos said, “so the level of distrust and fear is really big.”

‘Out of the shadows’

During Obama’s first presidential campaign, he spoke of undocumented immigrants, telling CNN in March 2007: “It’s absolutely vital that we bring those families out of the shadows.”

When his administration took power, the government was adding thousands of new agents hired at the end of President George W. Bush’s term and as a result ramping up enforcement efforts. Under pressure from Obama’s supporters to end Bush’s post-9/11 crackdown on illegal migrants, DHS tried to target these efforts.

“There were no comprehensive, written enforcement priorities,” said John Sandweg, a government affairs consultant who was a top immigration adviser to then-DHS Secretary Janet Napolitano. “Everyone in the country unlawfully was fair game.”

At ICE, then-Director John Morton put out two 2011 memos laying out the agency’s priorities: protecting public safety and national security; and securing the border. In a move cheered by activists, Morton also said agents could exercise “prosecutorial discretion” and decide not to deport certain illegal immigrants taken into custody based on factors such as their length of stay in the United States.

At the same time, DHS expanded a Bush administration program called Secure Communities. It allowed ICE to lodge official requests with local police departments that had arrested someone ICE wanted to deport. The requests called on police to hold the immigrants for up to 48 hours after their scheduled release so ICE could pick them up.

As Secure Communities took hold, deportations kept climbing, reaching an all-time high of more than 409,000 in 2012. Even as Republicans blasted the administration for what they called lax enforcement, prominent Latino and other groups derided Obama as the “deporter in chief.”

“There was a lot of big talk coming out of DHS, big promises that they were going to be more sensitive to immigrant families, said Nick Katz, a staff attorney for Make the Road New York, an immigrant rights group. “And then it didn’t make a fundamental impact on the ground.”

A new plan

Soon after Johnson took office in December 2013, he took on a presidential request. Obama — frustrated by the failure months earlier of legislation that would have given undocumented immigrants a path to citizenship — tasked the new DHS secretary with determining what the administration could do on its own.

A former corporate lawyer and Pentagon general counsel, Johnson immersed himself in the legal details, reading the 2011 ICE memos and earlier internal documents. He spotted what he considered some of the same flaws activists had pointed out, DHS officials said.

The 2011 ICE memos, for example, had put a priority on deporting people who reentered the country illegally after having been removed from the country before, even if the initial deportation was years earlier and they had since lived law-abiding lives in the United States. Long-term illegal immigrants with families and other community ties were being arrested — many under the Secure Communities program — for minor offenses and sent to ICE for deportation.

“These individuals were being picked up based on that priority, nothing else was looked at, and they were removed from the country before they had their day in court,” a second DHS official said.

A rebellion was also brewing against Secure Communities, which had been billed as a way to crack down on immigrants who had committed serious crimes. About 300 communities, including major cities such as Baltimore and Los Angeles, ended or scaled back their participation.

“In some ways, [Secure Communities] got away from itself,” the second DHS official said.

Johnson’s answer was a pair of memos, released in November on the same day as Obama’s much-publicized speech about the new DAPA program.

Johnson spelled out that immigrants could be deported only if they had been convicted of crimes, not just arrested. And he specified that only people who had crossed the border since January 2014 could be deported purely for an immigration violation, not someone who had been deported years earlier, reentered the country and lived a law-abiding life.

He also did away with Secure Communities, replacing it with a new Priority Enforcement Program to begin later this summer. Under this plan, ICE will still coordinate with local police about immigrants who are in custody but will ask to be notified 48 hours before the scheduled release of an immigrant who is targeted for deportation, rather than seeking to have immigrants held beyond their scheduled release.

Immigrant advocates expressed widespread skepticism about Johnson’s changes, saying they fear that long-term immigrants who are low-level offenders will still be targeted.

But Sandweg said they should keep an open mind. “I think these new priorities are in­cred­ibly significant,’’ he said. “They will obviously have an impact on the lives of millions of people.”

An earlier version of this article incorrectly said Kica Matos is director of human rights and racial justice at the Washington-based Center for Community Change. She is director of immigrant rights and racial justice at the Center.