The UK's intelligence assessment was that Kabul would not fall this year despite the Nato withdrawal from Afghanistan, Foreign Secretary Dominic Raab has said.
Mr Raab said intelligence analysts expected a "steady deterioration" rather than a swift collapse as the Taliban fought the Afghan security services.
Instead, Nato countries were caught out when the Taliban rapidly captured Afghan cities before taking over Kabul on August 15.
Defending Britain's handling of the crisis – and his own actions while on holiday in Greece – Mr Raab told a parliamentary committee that a similar view was shared among Nato allies.
He said ministers had planned for a worse scenario and made contingency plans to evacuate staff from its embassy in Kabul. About 15,000 people were eventually flown out of Afghanistan.
But "the central assessment was that it would be a Taliban consolidation of power, but that it would take place in the months following the evacuation and that Kabul would not fall before the end of the year", Mr Raab said.
"That was the central assessment, with all the usual caveats. That’s something that was widely shared, that view, among Nato allies."
Mr Raab played down suggestions that Britain and its European allies could have mounted their own defence of Afghanistan after the US withdrawal.
Washington's decision to pull out effectively left the hands of its Nato allies tied, leading to questions about the future of the alliance.
The foreign secretary said there had been "wishful thinking in some quarters internationally" that the White House could be persuaded to change its mind.
"I think if you look at the military capacity proportionally that the US put in, and therefore the shortfall, I don’t think there was any will and appetite," he said.
"I don’t think there was any viable alternative coalition once the US decision had been taken. There needs to be some reality about that in the public discourse."
Mr Raab was taking questions from MPs on a foreign affairs committee chaired by Tom Tugendhat, a vocal critic of the withdrawal. Mr Tugendhat described it on Wednesday as "the single biggest foreign policy disaster that the UK has faced since Suez".
The foreign secretary said he had not considered bowing to calls to resign after it emerged that he had delegated a call to Kabul, which ultimately never took place, on the day the Taliban took over the city.
He defended this on Wednesday. "Having a delegation and a division of labour between ministers, particularly my senior ministers of state, actually is an essential part of the work we do," he said.
Asked if he had any regrets, he said: "I haven't had a lot of time to sit back and muse and mull. But, of course, I'm always open to learning lessons from the future."
Questioned about the holiday to Greece that coincided with the evacuation, he said he would not have gone away in hindsight.
But "a modern Foreign Secretary has to have the ability… to be able to deal [with] work from abroad", he said.
The US withdrew its last remaining troops this week, bringing an end to its 20-year Nato presence in the country. The UK military airlift ended on Saturday.
Mr Raab declined to give a figure for people left behind, but said the number of British citizens was in the "low hundreds".
There are two separate schemes for Afghans to come to the UK. Those who worked for British troops will be offered permanent residency under a support package "Operation Warm Welcome".
European countries hope to persuade to the Taliban to allow safe passage out of Afghanistan. This was a key demand of a UN Security Council resolution backed by the UK, and Britain has held talks with the Taliban in Qatar.
Governments hope to enlist Afghanistan's neighbours, including Uzbekistan and Tajikistan, to allow passage through their territory and prevent a flood of refugees from reaching Europe.
Mr Raab said Britain wanted to show compassion to Afghans but maintain criteria so that "those that we want to come, come, rather than just opening the door".
He said a British rapid deployment team would be dispatched to areas where people trying to flee Afghanistan were likely to head.
Mr Tugendhat said he was doubtful over the government's talk of leverage over the Taliban, following reports of the militants targeting people who worked for the Nato-backed government.
Chris Bryant, an opposition Labour MP on the committee, said the different categories of people eligible to come to Britain seemed like "the left hand not knowing what the right is doing".
"Every MP has had individuals coming to their constituency surgeries, or ringing them up or emailing them, desperate about family members in Afghanistan," he told Mr Raab.