President Cyril Ramaphosa of South Africa said on Tuesday that his party, the African National Congress, had decided “it is prudent” to withdraw from the International Criminal Court — only for representatives for him and the party to later clarify that neither was actually advocating quitting the court, at least for now.
The A.N.C. would push for withdrawal only as a last resort, if other efforts aimed at ending what it considers the court’s inequitable treatment of certain nations failed, according to separate statements issued late in the night by a spokeswoman for the party and a spokesman for the president.
The shifting statements underscore the complexities and sensitivity of the matter at a fraught geopolitical moment, when South Africa and other countries are pushing back against a world order dominated by the United States and the West.
The I.C.C. has issued an arrest warrant on war crimes charges for President Vladimir V. Putin of Russia, who has been invited to a summit in South Africa in August. South African officials have not said whether they would honor their commitment to the I.C.C. and arrest Mr. Putin, and Mr. Ramaphosa said his government was still considering what to do.
Over the years, officials in South Africa and the governing African National Congress have argued that the I.C.C., and the international community in general, have come down harshly on African leaders and select countries like Russia, and given a pass to other nations, perhaps most notably Israel for what they believe is unjust violence against Palestinians.
“Our view is that we would like this matter of unfair treatment to be properly discussed,” Mr. Ramaphosa said during a news conference on Tuesday with Finland’s president. “But in the meantime, the governing party has decided once again that there should be a pullout.”
But within hours, the president’s spokesman, Vincent Magwenya, issued a statement saying that “the presidency wishes to clarify” that South Africa remained a signatory to the court and that the A.N.C. this past December had rescinded its earlier decision to withdraw from it.
The president, who was responding to a question about an A.N.C. statement regarding South Africa’s participation in the court, had “erroneously” given the impression that his country was withdrawing, the statement said.
The statement also said that South Africa “will continue to campaign for equal and consistent application of international law.”
While the statement made clear that South Africa would not imminently begin what would be a yearslong process of withdrawal, the president’s unscripted remarks touched off a media frenzy and highlighted the country’s different stance from much of the West on both the court and the war in Ukraine.
South Africa has refused pressure from its Western allies to condemn the Russian invasion. The two countries, along with China, held joint military exercises this year that overlapped with the first anniversary of the start of the war. Government and A.N.C. officials have repeatedly reiterated that South Africa and Russia are friends.
That South Africa was at least considering a withdrawal from the I.C.C. underscored that the A.N.C. was “clearly committed to a new world order” that was “not dominated by what is perceived to be Western interests,” said Gerhard Kemp, a law professor specializing in international criminal justice at the University of Derby in England.
The history of the court, which was created two decades ago as a standing body to investigate war crimes, genocide and crimes against humanity, does not support allegations of bias against African leaders. Of the nine cases involving African nations that the court has pursued, five resulted from requests by the African governments themselves, and two were referred to the court by the United Nations Security Council.
Two countries, Burundi and the Philippines, have left the court, in both cases following announcements that prosecutors planned to investigate their leaders for alleged atrocities. Gambia also quit briefly, but it rejoined the court after the country’s authoritarian ruler lost an election.
This is not the first time that South Africa has threatened to pull out of the I.C.C.
Following a dispute over whether to arrest the former president of Sudan, Omar al-Bashir, when he came to South Africa while under an I.C.C. arrest warrant in 2015, lawmakers brought up a bill in Parliament to withdraw from the court. The bill was eventually revoked when a court in South Africa ruled it unconstitutional.
Then on Tuesday, the A.N.C., which has been the governing party since South Africa’s first democratic elections in 1994, again railed against what it termed the West’s unilateralism. There was “a growing problem with the West threatening to violate international law and sidestepping international consensus in order to impose its will,” the A.N.C. said in a statement summarizing a meeting recently held by its national executive committee.
The West sees itself as “an enlightened civilization,” the statement continued, and it has claimed “to itself the right to impose its will on others in the name of human rights and democracy.”
Anushka Patil and Marlise Simons contributed reporting