But his pardon of Mr. Arpaio, 85, who became a lightning rod for controversy over his anti-immigrant views and accusations that he racially profiled Latinos, has prompted a fresh round of criticism, even from one of the top members of his own party.
On Saturday, the House speaker, Paul D. Ryan of Wisconsin, called the pardon an abuse of power that sent a dangerous signal.
Mr. Ryan “does not agree with this decision,” a spokesman, Doug Andres, said in a statement. “Law enforcement officials have a special responsibility to respect the rights of everyone in the United States. We should not allow anyone to believe that responsibility is diminished by this pardon.”
Mr. Trump ran on a message of curtailing immigration, and his message dovetailed with Mr. Arpaio’s. Republicans who were caught by surprise by Mr. Trump’s victory have been grappling with how to stand up against racism while making sure they do not alienate the older, whiter demographic of the party’s base.
Senator John McCain, Republican of Arizona, said that the president’s pardon “undermines his claim for the respect of rule of law, as Mr. Arpaio has shown no remorse for his action.” The state’s other Republican senator, Jeff Flake, who has been attacked by Mr. Trump and who is facing a primary challenge, was more muted.
“Regarding the Arpaio pardon, I would have preferred that the President honor the judicial process and let it take its course,” Mr. Flake wrote on Twitter.
Representative Trent Franks, another Arizona Republican, said he saw it as a just end to the saga of Mr. Arpaio’s legal entanglements.
“The president did the right thing — Joe Arpaio lived an honorable life serving our country, and he deserves an honorable retirement,” Mr. Franks posted on Twitter.
Outside Arizona, most Republicans stayed quiet. But Democrats laced into the president.
Jesse Lehrich, a spokesman for Organizing for Action, the political group that grew out of President Barack Obama’s campaigns, said the pardon “signals a disturbing tolerance for those who engage in bigotry.”
He added: “It sends an unsettling message to immigrants across the country. And it’s a repudiation of the rule of law. As a massive hurricane is hurtling toward the southern United States, the White House is focused not on saving lives, but on pardoning a man who committed unlawful acts of racial discrimination.”
The White House announced the pardon amid preparations for the storm, but the federal government said it was on top of the looming natural disaster.
Mr. Arpaio had become a staple of cable television for his roundups of people suspected of being in the country illegally in his heavily Latino state. After the Republicans lost the 2012 presidential election, the Republican National Committee conducted what came to be known as an election autopsy on what went wrong. The report concluded that the party needed to promote comprehensive immigration reform and do better outreach to Hispanics — guidance that Mr. Trump tossed aside during his campaign.
Many presidents have issued controversial pardons. Gerald R. Ford pardoned Richard M. Nixon. Bill Clinton pardoned Marc Rich, one of his donors, in his final days in office. By definition, pardons absolve someone of having broken the law.
But Mr. Arpaio had long been accused of abuses against minorities, including repeated violations of Fourth Amendment protections against unreasonable searches and seizures. His pardon struck a different political chord.
Paul Begala, a Democratic strategist who advised the main “super PAC” supporting Hillary Clinton in 2016, suggested that Mr. Trump was offering a different type of signal — one to people who might be approached by Robert S. Mueller III, the special counsel investigating ties between the Trump campaign and Russia, as well as possible obstruction of justice by the president when he fired Mr. Comey.
“The Arpaio pardon was awful in and of itself, but I also think it was a signal to the targets of the Mueller investigation that ‘I got your back,’” Mr. Begala said on Bill Maher’s HBO program on Friday night.
Mr. Arpaio was an early admirer of Mr. Trump. He appeared with him at a rally in Phoenix in 2015, and he vocally supported Mr. Trump’s interest in raising false questions about whether Mr. Obama, the first black president, was born in the United States.
Ari Fleischer, who was a press secretary under President George W. Bush, said that pardoning Mr. Arpaio did not “break new ground” in a decades-long debate over immigration.
But, echoing Mr. Begala, he said the concern was the message it sent to others who might receive pardons.
He said Mr. Bush used to wonder why presidents had the pardon power to begin with. “It does strike me as a constitutional anachronism,” Mr. Fleischer said.
“One should not be able to break the law thinking they have a protector in chief,” he added. “If mischief is connected to the White House and the president can pardon those who engaged in that activity, it leads to unlimited power.”
An earlier version of this article misstated the clemency that President Barack Obama gave to Chelsea Manning, the soldier who leaked national security information. Mr. Obama commuted Ms. Manning’s prison sentence, but did not issue a pardon.