The foreign ministries of Armenia and Azerbaijan said they would declare a “humanitarian truce” from midnight (2000 GMT, Saturday) after nearly three weeks of fighting over a disputed region.

It will be the warring sides’ second attempt to declare a ceasefire to quell almost three weeks of clashes over the disputed Nagorno-Karabakh region that have killed hundreds of people.

“The Republic of Armenia and the Republic of Azerbaijan have agreed to a humanitarian truce as of October 18, 00h00 local time,” Armenia’s foreign ministry said late Saturday.

Azerbaijan’s foreign ministry confirmed the move in an identical statement.

The announcement came after Russian Foreign Minister Lavrov held phone talks with his counterparts from Armenia and Azerbaijan and stressed “the need to strictly follow” a ceasefire deal agreed in Moscow last Saturday, the foreign ministry said.

The ministers also confirmed the importance of beginning “substantive” talks to settle the conflict, the ministry in Moscow said.

Armenia and Azerbaijan had last Saturday agreed to a ceasefire after 11 hours of talks mediated by Lavrov in Moscow, but then both accused each other of violating the deal.

Nagorno-Karabakh, a breakaway region of Azerbaijan mainly inhabited by ethnic Armenians and backed by Yerevan, has been the scene of deadly clashes since September 27.

According to an official, but partial, toll more than 700 people have been killed in the clashes.

The mountainous western region of Azerbaijan has remained under separatist Armenian control since a 1994 ceasefire ended a brutal war that killed 30,000.