Three British soldiers have been killed in Afghanistan by a gunman wearing a police uniform who opened fire on them as they prepared to leave a checkpoint.

In what appears to have been the latest "green-on-blue" incident, the gunman shot the three troops at checkpoint Kamparack Pul in Nahr-e-Saraj, Helmand province, during what should have been a routine visit on Sunday afternoon. All three were treated at the scene, but died from their injuries, the Ministry of Defence said.

The soldiers – two of whom were serving with the 1st Battalion Welsh Guards and one with the Royal Corps of Signals – had been working in an Afghan police advisory team and had been conducting a "shura", or consultation, with their colleagues. Next of kin have been informed.

In a statement, the MoD said the gunman struck as the three soldiers were preparing to leave. The suspect, who was also injured, is in custody. It is believed he is a member of the Afghan National Civil Order Police (Ancop), a special unit set up in 2006 and regarded as much more professional and highly-trained force compared to locally recruited officers.

The deaths come less than two months after two British soldiers were killed by an Afghan colleague at the British base in Lashkar Gah, Helmand's provincial capital. There have been seven green-on-blue incidents involving British forces since 2008, but also many others involving other members of Nato's International Security and Assistance Force (Isaf).

The inquiry into this latest episode will involve the Royal Military police's special investigations branch, which investigate whether the gunman had any links to the Taliban.

Isaf commanders know the insurgents have been seeking to undermine Nato's withdrawal plans by pressuring members of the Afghan national security forces to attack the foreign troops they are supposed to be working alongside. Isaf has been trying to encourage locals blackmailed by the Taliban to come forward, and in some cases has offered to relocate and protect those involved.

In other such incidents, however, violence has also been sparked by an argument or slight felt by an Afghan that has not been fully appreciated.

"It is too early to say what triggered this incident," said one source. "But we know the insurgents have felt the need to put pressure on Afghan police and army."

The checkpoint is regarded as a secure location, which the British soldiers had been to many times, so it is unlikely the gunman was an outsider who had managed to sneak in.

The deputy provincial police chief, Kamaluddin Sherzai, confirmed the suspect had been wounded and detained by British forces.

"A man in the uniform of civil order police opened fire to three foreign soldiers and killed them. The policeman was wounded and captured by the foreign forces."

His capture will give Isaf a rare chance to interview an Afghan who has turned his gun on a member of a foreign force – normally they are killed in any exchange of fire.

Map showing where attack took place

The shooting was by far the most serious of three security incidents in Helmand on Sunday and Isaf said that, overall, the number of serious attacks in the province has come down markedly in the last year.

The spokesman for Task Force Helmand, Major Ian Lawrence, said: "It is with deep regret that I must inform you that three soldiers, two serving with 1st Battalion Welsh Guards and one serving with the Royal Corps of Signals, have been killed in an incident at checkpoint Kamparack Pul in the Nahr-e-Saraj district of Helmand province."

"Their loss will be felt deeply across Task Force Helmand. However, this will be nothing compared to the grief experienced by the soldiers' families. Our thoughts and prayers are with them at this extremely difficult time."

The soldiers' families have been informed and have asked for a 24-hour period of grace before further details are released.

The overall number of green-on-blue incidents have risen in recent years. In 2011 there were 35 soldiers killed in 21 attacks by Afghan forces. This year at least 26 soldiers have been killed in 18 separate attacks by Afghan forces.

There have been several other attacks that did not lead to any foreign soldiers' deaths, but the Nato-led coalition does not report injuries.

Philip Hammond, the defence secretary, said: "I was saddened to hear of this cowardly act by a man wearing an Afghan uniform, which has taken the lives of three brave British soldiers. All of our thoughts are with the families of these men who have died in such tragic circumstances. They gave their lives protecting Britain's national security, helping to make sure that Afghanistan never again becomes a haven for international terrorism.

"Every day, tens of thousands of coalition forces, including UK personnel, live and work successfully with their Afghan counterparts to build an Afghan police force and army which can take the lead for their own security by the end of 2014. That process will continue, and though deeply tragic, yesterday's incident and attacks like it will not derail the mission or distract us from the task in hand.

"An investigation is now under way; we are determined to get to the bottom of exactly what happened yesterday at checkpoint Kamparak Pul, and to pursue those who are responsible."

General Sir David Richards, chief of the defence staff, said: "I was in Afghanistan with British troops last week where these deaths will be felt keenly. At the same time, I know that the resolve of those on operations will be unshaken. Generally, there remains a high level of trust between the Afghan forces and their British counterparts with whom they work and live every day. Every time I visit Afghanistan and I am struck by the progress we are making alongside the Afghans in building a country increasingly able to stand on its own two feet. Attacks like this will not stop us from moving forward."

Army cuts criticised

Cutting numbers in one of the army's most celebrated regiments is not a "sensible military option", according to a senior officer. Brigadier David Paterson, the honorary colonel of the Royal Regiment of Fusiliers, said he was "bitterly disappointed" by proposals to reduce the number of battalions in the regiment from two to one. In a letter written last month to General Sir Peter Wall, chief of the general staff, published in the Daily Telegraph, he wrote to ask why his regiment was facing cuts in spite of its strong performance in several areas. The army is in the process of reducing its numbers to 82,000 by 2020. The MoD said it would not comment on leaked documents. PA