South Sudan is withdrawing the case against four top politicians accused of treason that triggered the civil war, the justice minister has said.
The four, who include a former leader of the governing SPLM party, denied plotting a coup and also denied any links to the ongoing fighting.
Their release had been a key demand of the rebels.
Some one million people have been forced from their homes since fighting broke out in December 2013.
Justice Minister Paulino Wanawilla said that the case was being dropped in the interest of peace and reconciliation. He said that the four would probably be released by Friday.
Separately on Thursday, the UN Security Council threatened sanctions against those responsible for continued deadly violence in South Sudan.
In a strongly worded statement, council members expressed "horror and anger" over the mass killings of hundreds of civilians in the town of Bentiu, capital of the oil-rich Unity State, last week.
The charges against the four politicians carried the maximum sentence of death and related to an alleged coup attempt on 15 December.
South Sudan analyst James Copnall says this is a very significant step, because the trial was seen as a stumbling block to the peace talks in the Ethiopian capital, Addis Ababa.
In addition to former Sudan People's Liberation Movement (SPLM) secretary general Pagan Amum, ex-National Security Minister Oyai Deng Ajak was cleared, as were former Defence Minister Majak D'Agoot and former ambassador to the US Ezekiel Lol Gatkuoth.
In addition to the treason charge, they were accused of inciting the army and fuelling an insurgency in South Sudan, the world's newest state which became independent in 2011.
Earlier on Thursday, South Sudan President Salva Kiir sacked the head of the army following recent rebel advances. No reason was given for the dismissal of Gen James Hoth Mai.
Conflict first broke out in the capital, Juba, between troops loyal to Mr Kiir and those allied with his sacked deputy, Riek Machar.
It later spread to other parts of South Sudan, with numerous reports of ethnic killings.
Eleven ex-officials were arrested in December, but seven of them were later released.
The two sides signed a ceasefire agreement on 23 January, but sporadic fighting has continued.
The latest move comes amid worsening violence in South Sudan, with both sides implicated in atrocities and war crimes.
Last week, the United Nations accused the rebels of massacring hundreds of civilians who sought refuge in a church, mosque and hospital, after capturing Bentiu.
The rebels, however, blame the retreating government forces for the killings.
The UN Security Council expressed on Thursday its "readiness to consider appropriate measures against those responsible", which could mean sanctions.
It also said it was gravely concerned by the growing humanitarian crisis in a UN camp in Bentiu, where more than 23,000 people are seeking shelter.
Correspondents say the Bentiu killings are among the most shocking since the conflict began.