A ceasefire has taken hold in eastern Ukraine after the president's representative signed a deal with Russian-backed separatists in an effort to bring an end to nearly five months of fighting.
President Petro Poroshenko said he ordered government forces to stop hostilities following a protocol signed by representatives of Ukraine, Russia, the rebels and the Organisation for Security and Cooperation in Europe (OSCE) at talks in Minsk, the Belarusian capital.
"Human life is of the highest value. And we need to do everything that is possible and impossible to stop the bloodshed and end people's suffering," Mr Poroshenko said in a statement.
The Donetsk separatists said on Twitter that they also have ceased fire.
After announcing the ceasefire, negotiators met for two more hours and agreed upon the withdrawal of all heavy weaponry, the release of all prisoners and the delivery of humanitarian aid to devastated cities in eastern Ukraine, Heidi Tagliavini of the OSCE told reporters in Minsk.
Mikhail Zurabov, the Russian ambassador to Ukraine who also signed the deal, described the exchange of lists of more than 1,000 prisoners from each side as a "breakthrough".
Mr Poroshenko said a prisoner exchange could begin as early as Saturday and international monitors from the OSCE would keep watch over the ceasefire.
With the ceasefire deal, Russian President Vladimir Putin may hope to avert a new round of sanctions, which the European Union leaders ordered to be prepared
Since mid-April, Moscow-backed separatists have been fighting government troops in eastern Ukraine in a conflict the UN estimates has killed nearly 2,600 people and forced hundreds of thousands to flee their homes.
"The ceasefire will allow us to save not only civilians lives, but also the lives of the people who took up arms in order to defend their land and ideals," said Alexander Zakharchenko, the rebel leader from the Donetsk region.
Igor Plotnitsky, leader of the separatist Luhansk region, also told reporters that his forces would respect the ceasefire.
Moscow has denied reports by Ukraine, Nato and Western nations that it was backing the mutiny with weapons, supplies, and even with thousands of regular troops. But a Nato military officer said the number of Russian soldiers directly involved in the conflict has grown past Nato's earlier estimate of at least 1,000.
Leonid Kuchma, a former president of Ukraine, represented Mr Poroshenko at the talks.
"There was a genuine desire that there will be peace in that region. I think we will achieve it," Mr Kuchma said. He added, however, that even though both Mr Poroshenko and the separatist leaders have ordered their forces to stop fighting, "it doesn't mean that someone will not fire from behind the corner".
Mr Kuchma said they will set up a task force by Monday to organise not only the exchange of prisoners and delivery of humanitarian aid, but also to establish how the eastern regions of Ukraine will be governed.
At a summit in Wales, Nato leaders approved plans to create a rapid response force to counter Russian aggression, with a headquarters in eastern Europe that could quickly mobilise if an alliance country were to come under attack.
Ukraine is not a Nato member, but the entire alliance has been alarmed by Russia's actions in Ukraine, and Russia is under both US and EU sanctions for its backing of the rebels.
At the Nato summit, German Chancellor Angela Merkel said "if certain processes get under way, we are prepared to suspend sanctions" against Russia.
"(But) we have to see whether this ceasefire is being applied. Do Russian troops withdraw, so far as they're there? Are there buffer zones and things like that - a lot of things will have to be sorted out," she said.
A rebel offensive in south-east Ukraine in the last two weeks has turned the tide of the war against Ukrainian forces, who until recently had appeared close to crushing the rebellion.
On Friday morning, heavy shelling resounded north and east of the key south-eastern port of Mariupol.
The city lies on the Sea of Azov, between Russia to the east and the Crimean Peninsula to the west, which Russia annexed in March. The shelling appeared to indicate that rebels had partially surrounded the area.
The seizure of Mariupol would give the rebels a strong foothold on the Sea of Azov and raise the threat that they could carve out a land corridor between Russia and Crimea.
If that happened, Ukraine would lose another huge chunk of its coast and access to the rich hydrocarbon resources the Sea of Azov is believed to hold.
Ukraine has already lost about half its coastline, several major ports and untold billions in Black Sea mineral rights with Russia's annexation of Crimea.
"Mariupol is a strategic point. If we lose it then we could lose the entire coastline, the whole south of Ukraine," said Tatyana Chronovil, a Ukrainian activist at a mustering point for the volunteer Azov Battalion on the eastern edge of the city.
But as the ceasefire went into effect shelling died down in Mariupol for several hours and several Ukrainian tanks returned to the city. Some artillery shelling was heard in the rebel-held city of Donetsk after the ceasefire deadline, but it was not clear from which side.