The prime minister has told troops in Afghanistan he wants the British public to "revere and support" them for the "incredible work" they do.
David Cameron, who spent the night in Camp Bastion, said they could go home with "heads held high" once Afghans could manage their own security.
The troops cheered as he confirmed the operational allowance would double.
And Mr Cameron delivered a message from the England football team, who said the troops were "the real heroes".
"It's important you know how much all your effort means to the England players," the message said.
Earlier, soldiers had sent their own good luck video to the players ahead of the start of the World Cup.
'War of necessity'
This is Mr Cameron's first visit to Afghanistan since becoming prime minister.
Before heading to Camp Bastion on Thursday, he was forced to cancel a visit to a frontline patrol base in Helmand. There had been a warning about a possible attempt by Taliban insurgents to bring down his helicopter.
Earlier in the day, Mr Cameron announced an extra £67m to tackle the threat of roadside bombs and said the conflict was his "number one priority".
He said nobody wanted troops to be in Afghanistan "a moment longer than is necessary" - a sentiment he repeated on Friday morning to the ranks of soldiers gathered in the desert for his speech.
"This is not a war of choice, it is a war of necessity," the prime minister said, as he addressed personnel during a sandstorm.
"The Afghans aren't ready to look after their own security. As soon as they are ready we can leave and go home."
Mr Cameron said the government "didn't have some dreamy ideas" about trying to build "the perfect democracy" in Afghanistan.
Instead, the mission there was about protecting Britain's national security "pure and simple".
The PM said he wanted to give troops "proper support" by doubling their operational allowance, which currently stands at £2,380 for a six-month tour.
The increase will come into force from next month and be backdated to the date of the general election on 6 May.
He also said he wanted to "rewrite and republish the military covenant" - the pact of support between Britain and its armed forces - and put troops "front and centre of our national life again".
"I want you to help me create a new atmosphere in our country, an atmosphere in which we back and revere and support our military," he added.
On Thursday, Mr Cameron spoke alongside Afghan President Hamid Karzai at his presidential palace in Kabul.
The PM said 2010 was "the vital year" to make progress in stabilising the country.