Junta-ruled West African Sahel nations Mali, Niger and Burkina Faso signed a security pact Saturday promising to come to the aid of each other in case of any rebellion or external aggression.
The three countries are struggling with internal unrest as well as terrorism linked to al-Qaida and Daesh and have also seen their relations with neighbors and international partners strained because of the coups.
The latest coup in Niger drove a further wedge between the three and countries of the regional bloc, the Economic Community of West African States, which has threatened to use force to restore constitutional rule in the country.
Mali and Burkina Faso have vowed to come to Niger's aid if it is attacked.
"Any attack on the sovereignty and territorial integrity of one or more contracted parties will be considered an aggression against the other parties," according to the charter of the pact, known as the Alliance of Sahel States.
It said the other states will assist individually or collectively, including with the use of armed force.
"I have today signed with the Heads of State of Burkina Faso and Niger the Liptako-Gourma charter establishing the Alliance of Sahel States, with the aim of establishing a collective defence and mutual assistance framework," Mali junta leader, Assimi Goita, said on his X social media account.
All three states were members of the France-supported G-5 Sahel alliance joint force with Chad and Mauritania, launched in 2017 to tackle terrorist groups in the region.
Mali has since left the dormant organization after a military coup, while ousted Niger's President Mohamed Bazoum said in May last year that the force is now "dead" following Mali's departure.
Relations between France and the three states have soured since the coups.
France has been forced to withdraw its troops from Mali and Burkina Faso, and is in a tense standoff with the junta that seized power in Niger after it asked it to withdraw its troops and its ambassador.
France has refused to recognize the authority of the junta.