Leaders at an African summit have voted to give themselves immunity from prosecution for war crimes, crimes against humanity and genocide at a new African Court of Justice and Human Rights.

The continent already has two sitting presidents and one ousted president facing charges at the International Criminal Court.

The vote took place on Friday at an African Union summit vote in Equatorial Guinea, during a session journalists were excluded from, and news of it was only mentioned in a statement about the outcome of the summit on Monday, according to Amnesty International.

Download the new Independent Premium app Sharing the full story, not just the headlines

It came to light in a paragraph listing legal instruments agreed at the meeting included the "Protocol on Amendments to the Protocol on the Statute of the African Court of Justice and Human Rights".

The amendment bars the court from prosecuting sitting African leaders and vaguely identified "senior officials". It was objected to by forty-two African and international civil society and rights groups.

The decision was condemned by Amnesty International as "a backward step in the fight against impunity and a betrayal of victims of serious violations of human rights".

Amnesty's Netsanet Belay said: "At a time when the African continent is struggling to ensure that there is accountability for serious human-rights violations and abuses, it is impossible to justify this decision which undermines the integrity of the African Court of Justice and Human Rights, even before it becomes operational."

Ahead of the vote, Simon Allison of the South African-based Institute for Security Studies warned: "There are enough compromised African leaders who might stand to benefit from the immunity on offer."

He argued guaranteed immunity for presidents and senior officials might actually encourage African states to engage more enthusiastically with the proposed new court, and to abide by its rulings.

"If Africa's leaders aren't worrying about their own fate, they won't have anything to lose by cooperating," he added.

Additional reporting by Associated Press