Addis Ababa - World leaders on Thursday welcomed the security and oil deals between Sudan and South Sudan that eased tensions between the countries that came close to war in April.
Expressing a combination of relief and praise, Britain, the United States and the European Union all lined up to laud the deal.
"This agreement breaks new ground in support of the international vision of two viable states at peace with each other," US President Barack Obama said, calling for continued dialogue as the deal is implemented.
Britain's Foreign Secretary William Hague said it was a "significant stride" to help establish peace between the neighbours.
The European Union's foreign policy chief Catherine Ashton congratulated both sides in a statement on Thursday.
"This represents a historic step for both countries," she said.
Earlier, South Sudan's President Salva Kiir said the agreement "brings to an end the long conflict between our two countries".
Sudanese President Omar al-Bashir said he would "seize the historic opportunity and journey towards building peace".
The leaders signed a co-operation agreement after marathon talks in the Ethiopian capital that began on Sunday, a day after the rivals had missed a UN Security Council deadline to reach an accord.
However, the former civil war foes - who came close to renewed all-out war earlier this year - failed to strike a deal on the flashpoint region of Abyei as well as other contested border areas.
The breakthrough was reached late on Wednesday, including agreements that built on an oil deal last month, to ensure the resumption of oil exports after a stoppage that crippled the economies of both nations.
It included progress on a financial package of around $3bn that Juba has offered Khartoum, in recompense for Sudan's loss of key oil fields when the South broke free in 2011. The details however, were not immediately released.
Accusations over rebels
The two sides agreed on a demilitarised border buffer zone, where troops must withdraw 10km from the de facto line of control along the disputed frontier.
The buffer zone is also designed to cut support for rebel forces in Sudan's Southern Kordofan and Blue Nile regions, which Khartoum accuses Juba of backing, just as the South accuses Sudan of arming rebels in its territory.
Protracted talks under African Union mediation began in Addis Ababa several months before South Sudan split in July 2011 from what was Africa's biggest nation, following an independence vote after decades of war.
Recent mounting international pressure brought the long-running talks to a head, with teams spending the last few days and nights in frantic efforts trying to narrow positions.
The UN set a deadline for a deal after border fighting broke out in March, when Southern troops briefly wrested the valuable Heglig oil field from Khartoum's control and Sudan launched bombing raids in response.
The talks - originally billed as a one-day summit - had aimed to provide a comprehensive solution to the full range of disputes that had taken the rivals back to the brink of war.
Mbeki praises deal
Agreement on the contested flashpoint border region of Abyei - a Lebanon-sized border area currently controlled by Ethiopian peacekeepers - will have to wait however.
Kiir blamed his "brother Bashir" for the failure to reach a deal on Abyei, saying he had rejected an African Union proposal on the area "in its totality", but Bashir said he was committed to finding a solution.
The African Union's chief mediator, former South African president Thabo Mbeki, also praised the deal.
"We are convinced that what has happened constitutes a giant step forward for both Sudan and South Sudan," he said. "What this agreement says is that the governments are committed for no more war."
Outstanding issues will be addressed during future rounds of talks, officials said.
These include the violence and growing humanitarian crisis in Sudan's Southern Kordofan and Blue Nile states.
The two states are a source of bitterness between Khartoum and Juba, with Sudan claiming the South still backs its former civil war comrades who are rebelling there.
Oxfam said that while the agreements were "encouraging steps forward", the lack of a solution for these crisis regions remained a major concern.