South Africa's decision to withdraw from the International Criminal Court (ICC) has been ruled "unconstitutional and invalid" by the High Court.
South Africa notified the UN of its intention to leave last October, accusing the ICC of undermining its sovereignty.
But the opposition Democratic Alliance (DA) argued that the government had to first seek parliamentary approval.
The court ordered the government to revoke its notice of withdrawal.
The decision to pull out came after a dispute over Sudanese President Omar al-Bashar's visit to the country in 2015.
South African authorities refused to arrest Mr Bashir despite him facing an ICC arrest warrant over alleged war crimes.
Mr Bashir was attending an African Union summit in Johannesburg, when the government ignored an ICC request to arrest him.
The DA welcomed the judgement.
"The withdrawal by the South African government from the ICC was irrational and unconstitutional," DA lawmaker James Selfie told AFP.
"We would like South Africa to stay in the ICC because we believe that it is consistent with our constitution and with the legacy of Nelson Mandela."
Latest Stories
-
UNIDO commits to improving local rice standards
2 seconds -
Suleja prison: 108 inmates on the run in Nigeria
2 mins -
We object to government’s plans to make BEST sole off-taker of Sentuo Oil Refinery – CBOD
11 mins -
Burkina Faso army massacred 223 villagers in revenge attack – HRW
20 mins -
Germany detains alleged Nigerian mafia members
24 mins -
Manhyia Palace hosts royals, dignitaries from Ghana and beyond at special Awukudee
31 mins -
Celestine Donkor speaks on report of undergoing weight loss surgery
53 mins -
Bright Simons: The SML defence “falls flat”
1 hour -
We need long term macroeconomic stability to build a strong and vibrant economy – Deloitte Boss
1 hour -
Adomaa Adjeman to make theatre debut as Aku Sika in Prof Martin Owusu’s epic
1 hour -
U.S. government supports Ghanaian partners to protect Intellectual Property
1 hour -
Eric Johnson
1 hour -
Tanzania denies abuse reports as World Bank halts funds
1 hour -
2024 polls: The person I defeated twice can’t succeed me – Akufo-Addo
1 hour -
NBA: Miami Heat beat Boston Celtics to even series
2 hours