CAPE TOWN -- Warring factions in Ivory Coast agreed yesterday to end hostilities, start immediate disarmament, and make plans for new elections in an effort to prevent a renewed explosion of violence.
The agreement followed four days of talks in Pretoria mediated by President Thabo Mbeki of South Africa, who summoned all sides to his country's capital to try to rescue the peace process. The negotiations were the factions' first face-to-face meeting since civil war flared again last fall in the West African nation, the world's leading cocoa producer.
''The parties . . . hereby solemnly declare the immediate and final cessation of all hostilities and the end of the war through the national territory," said the agreement, signed in Pretoria.
''In this regard, they unequivocally repudiate the use of force as a means to resolve differences among themselves," the accord said, acknowledging the ''untold misery and suffering" inflicted on the Ivorian people and the disastrous economic repercussions of the fighting.
Ivory Coast has been split between the rebel-held north and the loyalist south since a failed coup attempt in 2002. A peace accord was reached in France in January 2003, but to little avail. A cease-fire reached in May of the same year was violated twice by President Laurent Gbagbo, raising doubts about elections.
UN Secretary General Kofi Annan yesterday welcomed the accord and urged both sides to fulfill their commitments ''promptly and in good faith," his spokesman Fred Eckhard said in a statement.
The agreement commits the warring factions to ''immediately proceed with the disarmament and dismantling of the militia throughout the entire national territory." It also scheduled a meeting for next Thursday between rebels and leaders of the armed forces to hammer out the details.
A copy of the deal, which was signed by Mbeki, Gbagbo, Prime Minister Seydou Diarra, former President Henri Bedie, opposition leader Alassane Ouattara, and rebel leader Guillaume Soro, was sent to the Associated Press in Cape Town.
Mbeki, who was mediating on behalf of the African Union, said all sides had agreed to the text after negotiations ran for two extra days.
To promote fairness and transparency, the agreement said the United Nations would be invited to participate in an Independent Electoral Commission comprising representatives of the ruling party as well as rebels.
The accord also gave a more prominent role to the prime minister, who is regarded as much more moderate and conciliatory than Gbagbo.
But the trickiest issue, the eligibility of presidential candidates, was not finalized. The current constitution contains a clause that all presidential candidates be second-generation Ivorians. As it stands, the clause effectively bars Ouattara -- a former prime minister who is considered Gbagbo's main opponent -- from running.
Mbeki said he was confident this could be sorted out within a week, according to the South African Press Association.
Gbagbo said he is committed to holding elections in October, as scheduled. ''Only elections can establish the authority of the state," the press association quoted him as saying.
The UN Security Council on Monday extended the mandate of its peacekeeping mission in Ivory Coast for a month to give more time to mediation efforts. The council had threatened sanctions to complement an arms embargo in place since November.
The Pretoria talks marked the first face-to-face meeting of all the factions since violence flared in November, when Gbagbo sent his newly built-up air force on bombing runs in the north.
One airstrike killed nine French peacekeepers and an American aid worker. French troops retaliated by destroying the air force, provoking anti-foreigner riots that caused thousands to flee as well as brief, unprecedented battles between French peacekeepers and Ivorian forces in the streets of Abidjan.
Last month, fighters supporting the government attacked a checkpoint in a rebel-held northern village, prompting insurgents to declare the peace process dead.
Insurgents had feared that government troops were deploying for new attacks, and UN peacekeepers reported a buildup of armed militias in government-held towns in the west along a buffer zone they patrol.