Armenia and Azerbaijan agreed on Tuesday to a Russian-brokered peace deal to end weeks of heavy fighting over Nagorno-Karabakh and find a long-term solution to the dispute over the region.
Here are the main points of the deal, which came after Azerbaijan managed to retake significant territory it had lost to Armenian separatists in a 1990s war over the region.
The deal was signed by Russian President Vladimir Putin, Azerbaijani President Ilham Aliyev and Armenian Prime Minister Nikol Pashinyan.
Ceasefire
A complete ceasefire and cessation of all hostilities was agreed from midnight Moscow time (21:00 GMT) on Tuesday.
The two sides will maintain positions in the territories they currently hold, a significant gain for Azerbaijan after it reclaimed some 15 to 20% of lost territory including the key town of Shusha.
Peacekeepers
A Russian force of 1,960 military personnel with small arms, 90 armored personnel carriers and 380 units of automobile and special equipment will deploy to the region to act as peacekeepers along the frontline and secure the Lachin corridor that links the region to Armenian territory.
The peacekeeping mission will last for five years and be automatically renewable for five-year periods as long as no party withdraws from the deal.
Return of territory
Armenia will return control to Azerbaijan of the Aghdam district by Nov. 20, the Kalbajar district by Nov. 15 and the Lachin district by Dec. 1.
The five-kilometer (three-mile) wide Lachin corridor will connect Nagorno-Karabakh with Armenia, bypassing its previous route through Shusha.
Prisoner exchange, refugees return
Internally displaced persons and refugees will return to the region and adjacent districts formerly under Armenian control.
The two sides will exchange prisoners of war and other detained persons, as well as bodies.
Corridor
Armenia will guarantee transport through the country from Azerbaijan to its Nakhchivan Autonomous Republic exclave on the border with Turkey, and the construction of transport communications will be provided.
The agreement makes no mention of the future status of the Armenian-populated areas of Nagorno-Karabakh or of the format of future negotiations to settle the conflict.