David Cameron has dismissed fears that Afghanistan could revert to a terrorist haven as he paid a pre-Christmas visit to troops in the country.
The Prime Minister defended newly announced plans for the British force to be almost halved to 5,200 next year.
Combat operations are due to end completely by 2014.
Critics have warned that Western forces are cutting and running from their 11-year engagement in Afghanistan, potentially opening the door to a "Taliban resurgence".
But during his traditional seasonal visit, Mr Cameron said he believes Afghan security forces are getting the "capability" to control the country.
"The fact is they are doing better than expected," he said in a round of broadcast interviews.
"This is withdrawal. This is draw-down based on success not on failure."
Pulling troops out is "being done for good military reasons and it has been done in a proper way".
He said: "We're confident it can be done while making sure Afghanistan does not return to become a haven of terrorism which is of course why we came here in the first place."
Mr Cameron admitted that Afghanistan is still a "deeply challenged country", but insisted: "It is a far better place than it was when we came here in 2001.
"We have paid a very heavy price but I think the reason for coming here in the first place, which was to stop Afghanistan being a haven for terror ... I think it was the right decision."
Referring to the evidence of terrorism plots that crosses his desk, the premier said: "Far fewer come from this part of the world than was the case when we first came to Afghanistan."
The Government has pledged an extra £230 million on military kit, with officials saying the move demonstrates its determination to see the campaign through.
The money, from the Treasury reserve, is being invested immediately.
The funding covers:
:: £29 million for additional IED detectors
:: More military working dogs for IED detection on foot patrols
:: £10 million to upgrade counter-IED capabilities on armoured vehicles
:: £5 million to boost intelligence, surveillance and reconnaissance at Camp Bastion.
Touring Camp Bastion in Helmand, Mr Cameron viewed vehicles now surplus to requirements and which are being sent home after troop numbers were cut by 500 to 9,000 this Christmas.
As well as being briefed by senior officers, he travelled to the smaller Camp Price base, 20 miles from Bastion, where he joined in a carol service with troops from 40 Commando Royal Marines. Songs included God Rest Ye Merry Gentlemen and Once In Royal David's City.
He also took on one marine at table football. After losing 2-1, Mr Cameron - who has faced speculation about his future as Tory leader - commented ruefully: "Someone better had better take over the blue team."
Brigadier Bob Bruce, commander of Task Force Helmand, said the capabilities of Afghan forces have "risen markedly" over the last eight to 12 months.
He told the BBC: "The Afghans working with us now really are in control. The insurgency is still there. It's not gone but it doesn't dictate things."
Head of the army General Sir Peter Wall said the withdrawal announcement was "consistent with the military plan to finish our combat operations here in Afghanistan by the end of 2014 having handed over successfully to the Afghan security forces".
Asked if the pullout timings could change, he added: "We will have to see how things play out but it is very much our intention to continue our handover to Afghan security forces who are doing a very good job.
"We have every reason to believe that they will continue on that track."
This morning Mr Cameron had breakfast with troops at Camp Bastion, including Private Emma Soult from Ashbourne, and Craftsman Sam Davidson-Webb from Ripon, of the Equipment Support Regiment.
He also handwrote a Christmas message that is being faxed to all the patrol bases in Helmand.
It said: "To you all. As a country we are always immensely proud of our armed forces, but this year you have made us prouder than ever.
"The professionalism and valour you have shown in Afghanistan has been remarkable and we can see real progress, with the successful handover to Afghan forces well under way.
"We should remember at this time especially all those who have been wounded or paid the ultimate price - and our prayers go out to their families.
"British forces have also served successfully all around the world including tackling the pirate and terrorist threats off the Horn of Africa. Our forces performed magnificently at the Olympic and Paralympic Games - putting a smiling face on the greatest show on Earth (and winning medals too).
"Your work has kept us safe for another year - and made us proud of what you do. Wherever you are this Christmas: thank you for your service.
"You are the BEST."
Speaking to journalists, Mr Cameron hailed Britain's military as "the best of the best" who made the country "incredibly proud".
"It is a good time to come to Afghanistan and say a really good thank you to our troops, and particularly Christmas time when they are away from their families," he said.
"Our military really are the best of the best and we cannot thank them enough for what they do."