GEORGE OURFALIAN via Getty Images A Syrian pro-government soldier runs for cover in the '1070' apartment block area, south of al-Hamdaniyah, in eastern Aleppo

BEIRUT, Dec 29 (Reuters) - A nationwide ceasefire in Syria, brokered by Russia and Turkey, which back opposing sides in the conflict, came into force at midnight on Friday, local time, (2200 GMT on Thursday) in the latest attempt to end nearly six years of bloodshed.

Russian President Vladimir Putin, a key ally of Syrian President Bashar al-Assad, announced the ceasefire on Thursday after preparing the agreement with Turkey, a longtime backer of the opposition.

A number of rebel groups have signed the agreement, Russia’s Defence Ministry said. Several rebel officials acknowledged the deal, and a spokesman for the Free Syrian Army (FSA), a loose alliance of insurgent groups, said it would abide by the truce.

One FSA commander was optimistic about the truce deal, the third attempt this year at a nationwide ceasefire.

“This time I have confidence in its seriousness. There is new international input,” Colonel Fares al-Bayoush said, without elaborating.

Khalil Ashawi / Reuters Rebel fighter clean a weapon in al-Rai town, northern Aleppo countryside, Syria December 25, 2016.

It is the first ceasefire deal reached without the involvement of the United States or the United Nations.

The previous two, brokered by Cold War foes Washington and Moscow, took effect in February and September but both collapsed within weeks as warring sides accused each other of truce violations and fighting intensified.

Putin said the parties were also prepared to start peace talks intended to take place in Astana, the capital of Kazakhstan. Syrian state media said late on Thursday that these talks would take place “soon.”

The Syrian government will be negotiating from a strong position after its army and their allies, including Shi’ite militias supported by Iran, along with Russian air power, routed rebels in their last major urban stronghold of Aleppo this month.

Moscow’s air campaign since September last year has turned the civil war in his favor, and the last rebels left Aleppo for areas that are still under rebel control to the west of the city, including the province of Idlib.

Before talks can take place, the ceasefire will have to hold.

Sputnik Photo Agency / Reuters Russia's President Vladimir Putin (C), Foreign Minister Sergei Lavrov (L), and Defence Minister Sergei Shoigu attend a meeting at the Kremlin in Moscow.

In a sign that the latest truce could be as challenging to maintain as its predecessors, there was confusion over which rebel groups would be covered by the ceasefire.

The Syrian army said the agreement did not include the radical Islamist group Islamic State, fighters affiliated to al Qaeda’s former branch the Nusra Front, or any factions linked to those jihadist groups.

But several rebel officials said the agreement did include the former Nusra Front - now known as Jabhat Fateh al-Sham - which announced in July that it was severing ties with al Qaeda.

The powerful Islamist insurgent group Ahrar al-Sham meanwhile said it had not signed the ceasefire agreement because of “reservations,” which it would make clear in due course.

Syria’s civil war, which began when a peaceful uprising descended into violence in 2011, has resulted in more than 300,000 deaths and displaced over 11 million people, half its pre-war population.