David Cameron said the fight against terrorism in north Africa would go on for years or "even decades" as he announced that a total of six Britons were thought to have died in the Algerian hostage crisis.

Three British nationals are known to have been killed, and three more were missing presumed dead, Cameron said in a statement from Chequers on Sunday morning. A British resident is also presumed to have been killed.

A further 22 Britons involved in the crisis at the In Amenas gas facility survived and have returned to the UK.

Speaking on the BBC's Andrew Marr Show, William Hague, the foreign secretary, said it was "quite likely" that some of the Britons were executed by the hostage-takers, who identified themselves as the Signers in Blood – a splinter group of al-Qaida in the Islamic Mahgreb.

In his statement, Cameron said he had spoken to his Algerian counterpart, Abdelmalek Sellal, and confirmed that it was clear that the "appalling terrorist incident" at the gas plant was over.

"Tragically, we now know that three British nationals have been killed, and a further three are believed to be dead. And also a further British resident is also believed to be dead," he said.

"I know the whole country will want to join me in sending our sympathies and condolences to the families who have undergone an absolutely dreadful ordeal, and now face life without these very precious loved ones."

Cameron said the attack had involved up to 30 terrorists and it illustrated that terrorism was a growing problem in north Africa.

"This is a global threat and it will require a global response. It will require a response that is about years, even decades, rather than months," he said.

"It requires a response that is patient and painstaking, that is tough but also intelligent, but above all has an absolutely iron resolve and that is what we will deliver over these coming years."

There are parallels between north Africa and Pakistan/Afghanistan, he said.

"It is different in scale but there are similarities. What we face is an extremist Islamist violent al-Qaida-linked terrorist group – just as we have to deal with that in Pakistan and in Afghanistan, so the world needs to come together to deal with this threat in north Africa. It is similar because it is linked to al-Qaida, it wants to destroy our way of life, it believes in killing as many people as it can."

Cameron said he would use Britain's chairmanship of the G8 this year to put the issue "at the top of the agenda" for the international community.

In his statement, Cameron said responsibility for the deaths "lies squarely with the terrorists who launched a vicious and cowardly attack". He did not criticise the Algerian government's handling of the crisis.

"No one should underestimate the difficulties of responding to an attack on this scale with 30 terrorists absolutely determined to take lives, and we should recognise all the Algerians have done to work with us and to help and co-ordinate with us, and I'd like to thank them for that," Cameron said.

In his BBC interview, Hague said London had not been consulted about the Algerian decision to launch the attack that terminated the crisis. "Of course, we would have liked to have been consulted," he said.

But he said the Algerians had acted swiftly because, according to the Algerian foreign ministry, the military thought the hostage-takers were planning to blow up the installation.

He also insisted the Algerian military knew how to deal with crises of this kind. "Whatever people think of them, whatever has been said about the Algerian military, they are experienced."

Hague said he did not know whether the Britons had been killed before the final assault, or while it took place. But, when asked if they had been "executed", he replied: "That sort of thing is quite likely to have happened."

Twenty-two Britons who survived the attack were back in the UK, he said. "We brought them back and BP brought others back on chartered flights during the night so they are being reunited with their loved ones," he said.

Hague also confirmed that Cameron's long-awaited Europe speech, which was originally scheduled for Friday, would go ahead this week. The date would be announced on Monday, he said.