Anti-government demonstrators in Ukraine have ended their nearly three-month occupation of Kiev's city hall, but tensions remained high as they vowed to retake it if the government fails to drop criminal charges against the protesters.

The decision to vacate the government building on Sunday was in exchange for President Viktor Yanukovich's promise to release all jailed protesters, the Associated Press news agency reported.

The building in Kiev's city centre had become the "headquarters of the revolution" since December when protesters trying to oust Yanukovich stormed and occupied it.

Under an amnesty arrangement aimed at defusing the crisis, Ukrainian authorities have offered to drop all criminal charges against activists who have been provisionally freed, as long as municipal buildings are cleared of protesters and some main roads unblocked by Monday.

The opposition has nevertheless warned that nothing short of Yanukovich's resignation will ultimately satisfy protesters.

After the protesters quit city hall, the Swiss ambassador in Kiev entered the building.

"Switzerland... was invited by both conflicting parties to participate in the process of transferring city hall to authorities," Ambassador Christian Schoenenberger told reporters.

Like other occupied buildings, city hall had been run with military precision, housing 600 to 700 protesters who slept there to escape the cold and also gathered for meetings, English lessons and other activities.

Activists had decorated the walls with scores of their own photos and satirical pictures, but the occupation was otherwise clean and orderly, with volunteers working in the kitchen, doling out medicine at a makeshift pharmacy or seeing patients.

Mass protests

The move to vacate the building comes just hours ahead of a new mass demonstration on Kiev's central Independence Square, which has become a sprawling, anti-government tent city barricaded off on all sides from riot police.

In a Saturday interview with weekly Dzerkalo Tyzhnia, jailed opposition icon Yulia Tymoshenko emphasised that "the only subject of negotiation with Yanukovich is the conditions of his departure".

She accused Yanukovich of having become a puppet of Russian President Vladimir Putin, saying Ukraine had lost the independence it gained from the Soviet Union in 1991.

"Our European friends believe that after long negotiations and loans they can bring Yanukovich back onto the European road," said the former prime minister, who was jailed in 2011.

"They will not be able to do that. Because it's not Yanukovich who decides, but Putin."

Andreas Umland, a political scientist at Kyiv-Mohyla Academy in the Ukrainian capital, said the government and opposition were thought to be negotiating a form of power-sharing agreement to be implemented before early presidential elections were held.

"For now the main question is whether Yanukovich will agree to power-sharing, what kind of power-sharing and how much power will be left to the office of the president," Umland said.

Source: Al Jazeera and agencies