The United States completed the withdrawal of its forces from Afghanistan on Monday (Aug 30), ending 20 years of war that culminated in the militant Taliban's return to power.
Forced into a hasty and humiliating exit, Washington and its NATO allies carried out a massive but chaotic airlift over the past two weeks, but still left behind tens of thousands of Afghans who helped Western countries and might have qualified for evacuation.
Celebratory gunfire rang out in Kabul after completion of the US pullout that ended America's longest war.
Taliban spokesman Qari Yusuf said: "The last US soldier has left Kabul airport and our country gained complete independence," Al Jazeera TV reported on Monday.
A contingent of Americans, estimated by US Secretary of State Antony Blinken as under 200 and possibly closer to 100, wanted to leave but were unable to get on the last flights.
President Joe Biden, in a statement, defended his decision to stick to a Tuesday deadline for withdrawing US forces even though it meant not everyone who wanted out could get out.
He said the world would hold the Taliban to their commitment to allow safe passage for those to want to leave Afghanistan.
"Now, our 20-year military presence in Afghanistan has ended," said Biden, who thanked the US military for carrying out the dangerous evacuation. He plans to address the American people on Tuesday afternoon.
Biden has drawn heavy criticism from Republicans and some of his fellow Democrats for his handling of Afghanistan since the Taliban took over Kabul earlier this month after a lightning advance.
Senator Ben Sasse, a Republican member of the Senate Intelligence Committee, called the US withdrawal a "national disgrace" that was "the direct result of President Biden's cowardice and incompetence."
"The president made the morally indefensible decision to leave Americans behind. Dishonor was the president's choice," he said in a statement.
But Democratic Senator Sheldon Whitehouse tweeted: "Bravo to our diplomats, military, and intelligence agencies. An airlift of 120,000 people in that dangerous and tumultuous situation is something no one else could do."
Biden has said the United States long ago achieved the objectives it set in ousting the Taliban in 2001 for harbouring al Qaeda militants who masterminded the Sept. 11 attacks on the United States.
The 20-year conflict took the lives of nearly 2,500 US troops and an estimated 240,000 Afghans and cost some $2 trillion (S$2.69 trillion).
Only 38 per cent of Americans approved of Biden's handling of the Afghan pullout, while 51 per cent disapproved, according to a Reuters/Ipsos opinion poll released on Monday.
Three-quarters of respondents wanted US forces to remain in the country until all American civilians could get out.
General Frank McKenzie, commander of the US Central Command, told a Pentagon briefing that the chief US diplomat in Afghanistan, Ross Wilson, was on the last C-17 flight out, which left at one minute before midnight in Kabul.
"Every single US service member is now out of Afghanistan. I can say that with 100 per cent certainty," he said.
"There's a lot of heartbreak associated with this departure. We did not get everybody out that we wanted to get out. But I think if we'd stayed another 10 days, we wouldn't have gotten everybody out," McKenzie told reporters.
Blinken said the United States was prepared to work with the new Taliban government if it does not carry out reprisals against opponents in the country.
"The Taliban seeks international legitimacy and support. Our position is any legitimacy and support will have to be earned," he said.
More than 122,000 people have been airlifted out of Kabul since Aug. 14, the day before the Taliban regained control of the country two decades after being removed from power by a US-led invasion.
Tuesday's deadline for troops to leave was set by Biden, fulfilling an agreement reached with the Taliban by his predecessor, Donald Trump to end US involvement in Afghanistan.
The United States and its Western allies scrambled to save citizens of their own countries as well as translators, local embassy staff, civil rights activists, journalists and other Afghans vulnerable to reprisals.
The evacuations became even more perilous when a suicide bomb attack claimed by Islamic State - enemy of both the West and the Taliban - killed 13 US service members and scores of Afghans waiting by the airport gates on Thursday.
Biden promised after the bloody Kabul airport attack to hunt down the people responsible.
The departure took place after US anti-missile defences intercepted rockets fired at Kabul's airport.
A US official said initial reports did not indicate any US casualties from as many as five missiles fired on the airport. Islamic State claimed responsibility for the rocket attacks.
In recent days, Washington carried out two air strikes. It said both hit Islamic State targets, one thwarting an attempted suicide bombing in Kabul on Sunday by destroying a car packed with explosives, but which Afghans said had struck civilians.
TALIBAN IN CONTROL
Most of the more than 20 allied countries involved in airlifting Afghans and their citizens out of Kabul said they had completed evacuations by Friday. Britain, closely involved in the war from the start, said on Saturday it had finished evacuations and withdrawn the last of its troops.
While the Taliban have sought to present a more moderate face to the world and erase memories of the harsh fundamentalist rule they practised in the 1990s, the desperation by many Afghans to flee the country showed clearly the fear inspired by the Islamist group.
Their seizure of the city on Aug. 15 after the Western-backed government collapsed without a fight and President Ashraf Ghani fled, completed a rapid campaign that saw them sweep up all the country's major cities in a week.
Now in full control of the country, the Taliban must revive a war-shattered economy but without being able to count on the billions of dollars in foreign aid that flowed to the previous ruling elite and fed systemic corruption.
Cut off from some $9 billion in foreign reserves and missing thousands of educated specialists who have joined the exodus, the inexperienced new administration must deal with a collapse in the afghani currency and rising food inflation.
Banks remain closed, despite promises they would reopen, and the economic hardship facing those left behind has worsened dramatically.
The population outside the cities is facing what UN officials have called a catastrophic humanitarian situation worsened by a severe drought. The UN refugee agency says up to half a million Afghans could flee their homeland by year-end.