Lieutenant-Colonel James Carr-Smith, spokesman for the Nato task force in Helmand, said: "We believe these were the actions of a lone individual who has betrayed his Nato and Afghan comrades. His whereabouts are currently unknown, but we are making strenuous efforts to find him."
The British defence ministry has called the incident a "suspected premeditated attack", in which it said the Afghan soldier used "a combination of weapons".
He had fired a grenade from a shoulder-mounted launcher at British soldiers
inside a base control room, Mohammad Zaher Azimi, the Afghan defence ministry spokesman, said.
In a message posted on a Taliban website, Qari Yousef Ahmadi, Taliban spokesman,
said the Afghan troop first opened fire with a machine gun on "soldiers who were sleeping" at the military base at about 1am.
The Taliban said the "heroic soldier" then "fired inside the enemy base", causing a blaze that destroyed ammunition and weapons.
The message said he then fled to a known Taliban location where he was received by members of the group, "who appreciated his work and took him to a safe place".
In a separate attack on Tuesday, a fourth British troop was shot and killed while on foot patrol in Sangin district, which is next to Nahrisaraj, where the assault by the Afghan soldier took place, British officials said.
Referring to the Helmand incident, David Cameron, the UK prime minister, condemned the "appalling" killings on Tuesday, but said there would be no change of tactics in Afghanistan.
"I think it's absolutely essential that we don't let this appalling incident change our strategy or our approach," he said.
"The right thing for us to do is to keep with our strategy of working with and building up the Afghan National Army ... it's when that happens that we will be able to bring our troops back home."
Cameron described the killer as a "rogue element" within the Afghan army.
"This is a combined, joint mission, Afghan and Alliance troopers fighting shoulder-to-shoulder against the Taliban and other extremists," General David Petraeus, US and Nato commander in Afghanistan, said in a statement.
"We have sacrificed greatly together, and we must ensure that the trust between our forces remains solid in order to defeat our common enemies.
Lieutenant-General Nick Parker, deputy commander of the Nato-led forces, said: "Our Afghan partners have got to look very carefully at what's happened and they've got to reassure us that they are doing everything they can to minimise it happening again."
Parker also said the vast majority of Afghan security forces were "real, genuine partners'' and that partnering the forces is key to the eventual exit of foreign forces.
"We have got to transfer security responsibility to the people whose country this is and if we don't do that, we're not going to succeed in our mission,'' he said.
Hamid Karzai, the Afghan president, sent a letter of condolence to Nato and Britain and offered his apologies over the incident.
Waheed Omar, a spokesman for the president, said that Karzai had asked the defence ministry to find out more about the incident.
"If it is confirmed, it's a very unfortunate attack and the government of Afghanistan will do everything to make sure the proper traitors are brought to justice," he said.
Tuesday's deaths bring to 356 the number of foreign troops to have died in the Afghan war so far this year, according to an AFP news agency tally based on a count kept by icasualties.org.
The total number for the whole of last year was 520 people.
In November, an Afghan police officer killed five British troops at a checkpoint in Helmand, where the UK has more than 9,000 soldiers.