Defense Secretary Jim Mattis, whose experience and stability were widely seen as a balance to an unpredictable president, resigned Thursday in protest of President Trump’s decision to withdraw American forces from Syria and his rejection of international alliances.
Mr. Mattis had repeatedly told friends and aides over recent months that he viewed his responsibility to protect the United States’ 1.3 million active-duty troops as worth the concessions necessary as defense secretary to a mercurial president. But on Thursday, in an extraordinary rebuke of the president, he decided that Mr. Trump’s decision to withdraw roughly 2,000 American troops from Syria was a step too far.
Officials said Mr. Mattis went to the White House with his resignation letter already written, but nonetheless made a last attempt at persuading the president to reverse his decision about Syria, which Mr. Trump announced on Wednesday over the objections of his senior advisers.
Mr. Mattis, a retired four-star Marine general, was rebuffed. Returning to the Pentagon, he asked aides to print out 50 copies of his resignation letter and distribute them around the building.
“My views on treating allies with respect and also being cleareyed about both malign actors and strategic competitors are strongly held,” Mr. Mattis wrote. “Because you have the right to have a Secretary of Defense whose views are better aligned with yours on these and other subjects, I believe it is right for me to step down from my position.”
His resignation came as Congress appeared to be hurtling toward a government shutdown and as a deep market slump became even worse over fears of continuing government turmoil.
With the ousting this month of John F. Kelly as White House chief of staff, Mr. Mattis was the last of Mr. Trump’s old-guard national security team — leaving policy in the hands of Mike Pompeo, the president’s second secretary of state, and John R. Bolton, the third White House national security adviser.
Mr. Trump said that Mr. Mattis, 68, will leave at the end of February, and that Mr. Mattis “was a great help to me in getting allies and other countries to pay their share of military obligations.”
The president said he would name a replacement soon.
As Mr. Mattis was handing in his resignation, the Pentagon was preparing to draw down forces in Afghanistan. Two Defense Department officials said Thursday that about 7,000 troops will be withdrawn in the coming months — cutting in half the number of American forces there — in an early step to ending the United States’ involvement in the 17-year war.
“This is scary,” Senator Mark Warner of Virginia, the top Democrat on the Senate Intelligence Committee, said in a Twitter post. He called Mr. Mattis “an island of stability amidst the chaos of the Trump administration.”
Senator Ben Sasse, Republican of Nebraska, called it “a sad day for America because Secretary Mattis was giving advice the President needs to hear.”
He added that Mr. Mattis “rightly believes that Russia and China are clear adversaries and that we are at war with jihadists across the globe who plot to kill Americans at home.”
Mr. Mattis’s resignation letter was the sharpest, and most public, protest from inside the Trump administration over the president’s rejection of the alliances and relationships that have underpinned American security since the end of World War II.
It was also the first resignation over a major national security issue by a leading cabinet member since 1980, when Cyrus Vance quit as secretary of state. Mr. Vance left over President Jimmy Carter’s decision to attempt a rescue effort for American hostages in Iran that Mr. Vance considered ill-advised and that ended in tragedy.
Since President Trump’s inauguration, White House staffers and cabinet officials have left in firings and resignations, one after the other.
Mr. Mattis’s letter did not single out any decision. Instead, it condemned Mr. Trump’s approach to the world as destructive to American influence and power.
He said the core of American national interests lay in “providing effective leadership to our alliances,” and specifically described the importance of the North Atlantic Treaty Organization, a defense alliance Mr. Trump has often derided. Mr. Mattis also praised the “Defeat ISIS” coalition that Mr. Trump just abandoned in Syria.
But Mr. Mattis’s core complaint was that Mr. Trump had lost sight of the importance of the competition for global power with Russia and China, who want “a world consistent with their authoritarian model.”
Mr. Mattis was the primary author of a new American defense strategy whose central goal was to take on “revisionist” powers — an approach that some of Mr. Trump’s former advisers say the president never fully comprehended.
Mr. Trump’s decision to pull out of Syria, which was opposed by virtually every high-level administration official but lauded by President Vladimir V. Putin of Russia, was the last straw. Among his other concerns, Mr. Mattis viewed the withdrawal as abandoning Kurdish fighters and other American allies, and as ceding critical territory to Russia and Iran.
No senior Pentagon official has defended the withdrawal publicly, despite requests from the White House. As a result, Mr. Trump appeared by himself in a video — which he tweeted Wednesday evening — announcing victory over the Islamic State.
During Thursday’s meeting at the White House, officials said that Mr. Trump again asked Mr. Mattis to publicly endorse the Syria decision. Mr. Mattis refused.
The president’s tweets announcing the departure of his defense secretary shocked officials at the Pentagon, who as recently as Thursday afternoon were insisting that Mr. Mattis had no intention of resigning.
Mr. Trump’s selection of Mr. Mattis as his Pentagon chief only weeks after his 2016 election was widely praised. The career Marine was respected among allies and adversaries and on Capitol Hill, and he was beloved in the Pentagon as a protector against a president with scant understanding of his own role as commander in chief.
Mr. Mattis commanded Marines in Afghanistan and in the 2003 invasion of Iraq before becoming the head of United States Central Command, overseeing all American troops in the Middle East. Though a colorful, hard-charging advocate of aggressive offensive action, Mr. Mattis viewed a tough American posture overseas as a way to deter war, not to start them, with potential foes like Iran.
He favored working with allies, and often spoke of how difficult it was to conduct American policy without the benefit of friends. During his job interview with Mr. Trump in 2016, Mr. Mattis said he did not believe in torturing terrorism suspects to get information because he thought he could get more out of detainees by talking to them over a pack of cigarettes and a beer.
The relationship between Mr. Mattis and Mr. Trump had deteriorated for months. The widely accepted narrative that Mr. Mattis was the adult in the room when at the White House came to annoy the president. In October, Mr. Trump accused Mr. Mattis of being a Democrat — a charge akin to treason in the current Republican administration.
As defense secretary, Mr. Mattis oversaw the world’s most powerful military, supervising active-duty troops based in the United States and deployed worldwide, including in war zones in Afghanistan, Iraq, Syria and on the Saudi border with Yemen. There are also around 25,000 American troops in South Korea, where they have served for generations as a deterrent against North Korea.
As with Mr. Trump’s abrupt firing of Attorney General Jeff Sessions, the split with Mr. Mattis was a full turn in a relationship that once appeared strong.
In Mr. Mattis’s early days as defense secretary, he often ate dinner with the president in the White House residence. Over hamburgers, and with the help of briefing folders, Mr. Mattis explained to Mr. Trump key points about the United States’ relationships with allies.
But Mr. Mattis also quietly slow-walked a number of Mr. Trump’s proposals, including banning transgender troops, starting a Space Force and putting on a costly military parade. In each case, he went through the motions of acquiescing to the White House — and then buried the plans in Defense Department red tape.