Suspected jihadists massacred more than 40 civilians in northern Mali and killed 12 troops in an ambush in neighbouring Burkina Faso, officials said Monday, highlighting the security crisis gripping the two fragile states.

More than 40 people were killed on Sunday when "terrorists" invaded the villages of Karou, Ouatagouna and Daoutegeft near Mali's border with Niger, a military officer told AFP.

"The terrorists went into the villages and massacred everyone," the source said, speaking on condition of anonymity.

A local official, who also asked not to be identified for security reasons, said that "20 civilians were massacred in Karou. Fourteen civilians were killed in Ouatagouna, and other civilians were killed in the hamlet of Daoutegeft."

Malian strongman Assimi Goita has led two coups in the last year
Malian strongman Assimi Goita has led two coups in the last year AFP / MALIK KONATE

The assailants arrived on motorbike, taking the villagers by surprise, he said.

An official at a fourth village said his locality had also come under attack.

An army unit has been sent to provide help, a military officer said, but a source in a Malian NGO said communications with the area were poor after jihadists had attacked telecoms sites.

Mali, a landlocked and impoverished state in the heart of the West Africa's Sahel region, has been battling a jihadist insurgency since 2012.

Jihadist violence has caused hundreds of thousands of Malians to flee their homes
Jihadist violence has caused hundreds of thousands of Malians to flee their homes AFP / OLYMPIA DE MAISMONT

The crisis began with unrest in the north of the country that spread to Mali's ethnically volatile centre and then to neighbouring Niger and Burkina Faso.

Armed groups linked to Al-Qaeda and the Islamic State group are steering the campaign today.

Thousands of civilians and troops have died and hundreds of thousands of people have fled their homes.

Mali has suffered two coups since August last year, and on July 20 military leader Colonel Assimi Goita survived an attempted assassination at a mosque in Bamako.

World map showing countries where jihadists are operating.
World map showing countries where jihadists are operating. AFP / Jonathan WALTER

Alioune Tine, an independent experts on human rights in the Sahel who reports to the United Nations, last week warned that a "critical threshold" had been breached in the country's security situation.

At the end of an 11-day visit, he highlighted "the failure of the institutions of state" as well as "relentless attacks on civilian populations" by jihadists, and said the armed forces themselves had committed violence against civilians.

In Burkina Faso, meanwhile, 12 troops were killed and eight were wounded on Sunday in an ambush near the border with Mali, the government said.

"Members of the ground forces and the rapid intervention force GARSI were ambushed" in the northwest Boucle du Mouhoun region, Communications Minister Ousseni Tamboura said on Monday.

The attack occurred near the village of Dounkoun in Toeni district.

President Roch Marc Christian Kabore said in a tweet that "we continue to wage without concession the war the obscurantist and barbaric forces have imposed on our country."

A security source told AFP that the ambush happened around 3 pm (1500 GMT), adding vehicles had been destroyed or captured.

The attack was "revenge for the death of two jihadist leaders who were active in the same Boucle du Mouhoun region, who were neutralised (Saturday) by the armed forces," the source added.

He named the two leaders as Sidibe Ousmane, also known "Mouslim" and spiritual leader Bande Amadou, the source said.

They were killed by a special army unit following exchanges of fire between Diamasso and Bouni, in Kossi province, the government said Sunday in a statement.