The last US and Nato forces have left Bagram airbase in Afghanistan, the epicentre of the war against jihadist militants for some 20 years.
The pull-out could signal that the complete withdrawal of foreign forces from Afghanistan is imminent.
President Joe Biden has said US forces will be gone by 11 September.
But the withdrawal from the sprawling base, north of Kabul, comes as the main jihadist group, the Taliban, advances in many parts of Afghanistan.
The 11 September deadline is the anniversary of the attacks on America in 2001, which killed nearly 3,000 people.
The attacks were carried out by al-Qaeda, an international jihadist group then based in Afghanistan with the support of the Taliban, who had been in control of the country since the 1990s. A US-led coalition invaded the Afghanistan later that year to defeat both groups.
America now wants to end its longest war with its huge cost in human lives and vast expense, and is leaving security to the Afghan government.
Some 2,500-3,500 US troops were thought to be still in Afghanistan until recently, and they are due to depart along with some 7,000 other coalition troops, leaving fewer than 1,000 American soldiers in the country.
Meanwhile, a resurgent Taliban, buoyed by the expectation of the foreign withdrawal, has overrun dozens of districts, amid fears that a new civil war could erupt after the departure of foreign forces.
Bagram is a bellwether of what’s to come. This symbol of American military might was once a stronghold of Soviet forces. Now Afghan security forces will soon confront the challenge of securing this sprawling city within a city.
Bagram is vital – in symbolic and strategic ways. Taliban fighters, advancing in districts across the country, have this prize in their sights. Even last October, residents of the town which has swelled all around it told us the Taliban were already in their midst.
On a recent visit to the base, as the US packed up, we heard how Afghan security forces saw it as a mixed blessing. There’s a wealth of military assets within its walls; but that treasure is a top target for Taliban, not to mention corrupt commanders and others eying this fortune.
For the countless Afghans whose lives and livelihoods have long banked on this base – and who now feel abandoned – Bagram’s new chapter is deeply worrying.
How big is Bagram Airfield?
The airfield, built up by the Soviets when they occupied Afghanistan in the 1980s, and named after a nearby village, lies around 40km (25 miles) north of Kabul.
The US-led coalition forces moved in during December 2001, and it was developed into a huge base capable of holding up to 10,000 troops.
It is served by two runways, the most recent of which is 3.6km long, where large cargo and bomber aircraft can land.
It has 110 parking spots for aircraft, which are protected by blast walls, and had a 50-bed hospital with a trauma bay, three operating theatres and a modern dental clinic, the Associated Press reports.
Its hangars and buildings included the main prison facility for people detained by US forces at the height of the conflict, which became known as Afghanistan’s Guantanamo – after the infamous US military prison in Cuba.
Bagram was one of the sites identified in a US Senate report on the CIA’s interrogation of al-Qaeda suspects, including the use of torture, carried out in detention facilities.
What happens next?
An official ceremony to mark the handover of Bagram is expected to be held on Saturday, an Afghan official told Reuters news agency.
About 650 US troops are expected to remain in the country, the Associated Press reports, to provide protection for diplomats and help guard Kabul’s international airport, a vital transport hub for the landlocked country.
They are guarding the airport alongside troops from America’s Nato ally Turkey, while a new agreement for its security is negotiated with the Afghan government.
The airport’s US protection includes a counter-rocket, artillery, mortar system and the troops to operate it, as well as helicopter support.
Other American troops will guard the US Embassy in Kabul.
Military analysts say the ability of the Afghan government to maintain control over Bagram will be vital to its efforts to defend Kabul and push back the Taliban.
While the Taliban stopped attacks on coalition forces after signing an agreement with the US in February of last year, they have continued fighting government forces.
A Taliban spokesman, Zabihullah Mujahid, welcomed the US withdrawal from Bagram, telling AFP news agency it would “pave the way for Afghans to decide about their future between themselves”.
The war is thought to have taken the lives of more than 47,000 Afghan civilians and nearly 70,000 Afghan troops, as well as the lives of 2,442 US soldiers and more than 3,800 US private security contractors, and 1,144 soldiers from other coalition countries.
The Costs of War project at Brown University, which analyses America’s wars this century, estimates that the war has cost America a total of $2.26tn (£1.64tn).