This has been updated with the latest.

With the withdrawal from Afghanistan turning deadly for U.S. troops, President Biden faces new criticism for a situation that he argues presents him few options.

The deal that President Donald Trump cut last year with the Taliban forced Biden to choose between a withdrawal now or an escalation of the war, Biden said Thursday, as he addressed the nation after at least 13 members of the U.S. military were killed in Kabul.

He chose to withdraw.

“I had only one alternative,” he said, “to send thousands more troops back into Afghanistan to fight a war that we had already won, relative to the reason why we went in the first place.”

When the deal was cut in Doha, Qatar, in February 2020, it wasn’t treated as huge news, because the war itself wasn’t big news. So many people don’t actually know its contents.

Here is what’s in it and how it has been perceived.

President Biden said he had asked for plans to strike ISIS-K assets in light of the Aug. 26 attacks in Kabul that killed civilians and 13 U.S. service members. (The Washington Post)

Why Trump cut the deal

When Trump came into office, he was pretty transparent — he just wanted out of Afghanistan. “Trump had no real sense of what was at stake in the war or why to stay,” writes Georgetown professor Paul Miller in a digestible history of the 20-year war.

So Trump took a swing at something his predecessors hadn’t: a full-bore effort to strike a deal with the Taliban. It took nine rounds of talks over 18 months. At one point, Trump secretly invited the Taliban to the presidential retreat at Camp David on the eve of the anniversary of the Sept. 11, 2001, terrorist attacks. But he shut that down — and on Twitter threatened to shut down all talks — after an American service member was killed and there was bipartisan backlash over the invitation.

Talks continued in Doha, and in February 2020, Trump announced that there was a deal. The basic contours: The United States was to get out of Afghanistan in 14 months and, in exchange, the Taliban agreed not to let Afghanistan become a haven for terrorists and to stop attacking U.S. service members.

The Taliban also agreed to start peace talks with the Afghan government and consider a cease-fire with the government. (The Taliban had been killing Afghan forces throughout this, attempting to use the violence as leverage in negotiations, U.S. intelligence officials believed.)

The deal laid out an explicit timetable for the United States and NATO to pull out their forces: In the first 100 days or so, they would reduce troops from 14,000 to 8,600 and leave five military bases. Over the next nine months, they would vacate all the rest. “The United States, its allies, and the Coalition will complete withdrawal of all remaining forces from Afghanistan within the remaining nine and a half (9.5) months,” the deal reads. “The United States, its allies, and the Coalition will withdraw all their forces from remaining bases.”

The United States would release 5,000 Taliban prisoners; the Taliban would release 1,000 of its prisoners.

The Taliban’s end of the deal asked a lot from the group — too much to be realistic, critics said. In addition to making sure nowhere in the country harbored a terrorist cell, the Taliban agreed to be responsible for any individual who might want to attack the United States from Afghanistan, including new immigrants to the country.

The Taliban “will send a clear message that those who pose a threat to the security of the United States and its allies have no place in Afghanistan,” the deal read. And the Taliban agreed to “prevent any group or individual in Afghanistan from threatening the security of the United States and its allies, and will prevent them from recruiting, training, and fundraising and will not host them in accordance with the commitments in this agreement.”

This deal required taking the Taliban’s promises on faith.

“I really believe the Taliban wants to do something to show that we’re not all wasting time,” Trump said as he announced the agreement. He added as an aside: “If bad things happen, we’ll go back with a force like no one’s ever seen.”

The deal was a sweet one for the Taliban, critics say

One gaping problem, say scholars (including some from the Trump administration): The peace agreement came with no enforcement mechanism for the Taliban to keep its word.

The Taliban basically had to sign a pledge saying it wouldn’t harbor terrorists. Nowhere did the Taliban have to — nor did it choose to — denounce al-Qaeda, the terrorist group that launched the 9/11 attacks from Afghanistan, Miller writes.

The biggest tangible commitment from the Taliban looked like this: For seven days before the deal was signed, its leaders significantly reduced their attacks on Afghan forces to show they were capable of controlling the group across the country. But the deal didn’t require that the Taliban stop its attacks against Afghan security forces.

Overall, it was a pretty good deal for the Taliban, critics said. “Trump all but assured the future course of events would reflect the Taliban’s interests far more than the United States,” Miller writes. H.R. McMaster, Trump’s second national security adviser, has recently called it “a surrender agreement with the Taliban.” Another member of Trump’s National Security Council said it was “a very weak agreement.”

As The Fix’s Aaron Blake notes, former Trump officials are suddenly and conspicuously scrambling to distance themselves from that deal.

Cracks in the deal emerge almost immediately

A few months after the agreement was signed, there was plenty of evidence that the Taliban wasn’t as sincere as it appeared about peace. The United Nations said it had evidence that the Taliban and al-Qaeda still had ties. U.S. intelligence warned that al-Qaeda was “integrated” into the Taliban. The Taliban launched dozens of attacks in Afghanistan, ramping up its violence.

“The Taliban views the negotiations as a necessary step to ensure the removal of U.S. and other foreign troops under the U.S.-Taliban agreement, but the Taliban likely does not perceive that it has any obligation to make substantive concessions or compromises,” a U.S. inspector general report read.

It was all enough that when Biden came into office, U.S. officials questioned whether the Taliban was breaking its side of the deal.

But Trump chose to continue taking U.S. troops home

And he had bipartisan support for it.

It’s important to remember that by the time Trump came into office, the public debate about whether to stay in Afghanistan was largely over. Most Americans were done with the war. Even the military realized it couldn’t effect much more change on the current course. “The only way forward was going to be a political agreement,” Mark T. Esper, Trump’s former defense secretary, said recently. “Not a military solution.”

To a number of those who were paying attention, the whole deal felt like a naked attempt to just get out of Afghanistan. It was a campaign promise of Trump’s to be the president who finally ended America’s longest war. It would be something no other president had been able to accomplish.

Before the peace talks really got going, Trump had already started withdrawing thousands of troops, and he fired his defense secretary, Esper, after he wrote a memo disagreeing. (Esper later said that Trump’s withdrawing too many troops too soon contributed to what we see now in Afghanistan.)

Biden criticizes the deal but hews to it

When Biden took over, there were just 3,500 U.S. troops left in the country (from a high of 100,000 during the Obama years). He pushed back the date of the planned withdrawal from May 1 to four months later, but he kept the deal intact. U.S. troops would be out of Afghanistan by the 20th anniversary of the 9/11 attacks.

“It’s time to end America’s longest war,” he said.

The Taliban didn’t even wait for the Americans to completely leave before it took over the country in a matter of days. As the world watched Kabul fall, Biden has defended his decision not to stay and fight by saying Trump’s deal required him to either maintain the withdrawal or escalate fighting.

“When I became president, I faced a choice — follow through on the deal, with a brief extension to get our forces and our allies’ forces out safely, or ramp up our presence and send more American troops to fight once again in another country’s civil conflict,” he said in a statement.

On Thursday, he credited the deal for the fact that the Taliban hadn’t attacked Americans during the withdrawal. “The commitment was made by President Trump: I will be out May 1st. In the meantime, you agree not to attack any Americans. That is the deal. That’s why no American was attacked.”

Critics have contended that’s a false choice, noting how many other international agreements of Trump’s that Biden has eschewed or rewritten. But given that Biden shared the goal to withdraw, it left him little leverage to renegotiate with the Taliban.

For both presidents, the peace deal with the Taliban presented a good opportunity to pursue their own agendas with regard to America’s longest war. And neither has seemed particularly regretful about doing so.

“Leaving having proposed a peace effort and then blaming the Afghans for not reaching peace is as good a cover for leaving as any,” said Anthony Cordesman, a Middle East expert at the Center for Strategic and International Studies.