Thousands of protesters celebrated after police withdrew from Istanbul’s Taksim Square, the focal point of nationwide protests against Turkey’s Islamist-rooted government.

The government, while acknowledging some excesses by police in two days of clashes, called on the demonstrators to leave the streets after protests in 48 cities.

Rights groups denounced police violence, with Amnesty International saying that there had been two deaths. Turkey’s Western allies Britain and the United States have called for the government to exercise restraint.

According to official figures, the clashes over the last few days have left dozens injured. Amnesty put the figure in the hundreds and said that some protesters had been left blinded by the massive quantities of tear gas used by police.

Overnight Saturday, however, protesters in Taksim Square were celebrating their victory over the police, dancing and singing, with some even launching fireworks.

What began as an outcry against a local development project snowballed into a broader protest against what critics say is the government’s increasingly conservative and authoritarian agenda.

And since the first clashes on Friday, the unrest has spread to dozens of other cities across the country.

On Saturday, police in Ankara blocked a group of demonstrators from marching on parliament and the prime minister’s office.

Speaking at a rally Saturday, Erdogan acknowledged:

“It is true that there have been some mistakes, extremism in police response.”

But he added: “I call on the protesters to stop their demonstrations immediately.”

He also vowed to push forward with controversial plans to redevelop the square — the issue that sparked the protests.

The interior ministry promised legal action against police officers who had acted “disproportionately.”

At Taksim Square, a popular tourist destination and traditional rallying site in Istanbul, the mood was defiant.

“We are still ruled by a prime minister who thinks people are lambs and declares himself the sultan,” said 19-year-old law student Batuhan Kantas, sitting exhausted on the ground.

Turkey’s President Abdullah Gul called for restraint on both sides.

Interior Minister Muammer Guler said that 53 citizens and 26 police officers had been injured across the country, with one person in intensive care at an Istanbul hospital.

The minister also said police had detained 939 protesters in more than 90 demonstrations in 48 cities, though some had later been released.

Officials said a dozen people were being treated in hospitals.

But Amnesty International spoke of reports of two deaths and more than a thousand injured, although there was no official confirmation of those figures.

In a statement, it said they opened its Istanbul offices, near Taksim Square, to give sanctuary to protesters and 20 doctors were treating injured protesters there.

Amnesty’s Europe director John Dalhuisen said police excesses in Turkey had become routine.

“But the excessively heavy-handed response to the entirely peaceful protests in Taksim has been truly disgraceful,” he added.

Human Rights Watch also suggested the real casualty figure was much higher than the official figures. One protester had lost an eye after police shot him with a plastic bullet, the group reported.

The US State Department called on Turkey to uphold “fundamental freedoms of expression, assembly and association, which is what it seems these individuals were doing”.

“We urge authorities in Turkey to exercise restraint and not to use tear gas indiscriminately,” the British foreign office tweeted on Saturday.

The Istanbul protest began as a peaceful sit-in at Gezi park across the iconic square.

The demonstrators had been preventing workers from razing some of the park’s 600 trees, the last patch of green in the commercial area, to make way for the restoration of Ottoman era military barracks. Residents fear that the barracks will be turned into a shopping mall.

But the demonstration soon took a violent turn after police fired rounds of tear gas to disperse the protesters.

Clashes raged overnight Friday to Saturday with thousands of people marching through the city, some banging pots and pans as residents shouted support from the windows.

Others held up cans of beer in defiance of a recent law by the ruling Justice and Development Party (AKP) that will restrict the sale and advertising of alcohol.

Erdogan’s populist government is regularly accused of trying to make the predominantly Muslim but staunchly secular country more conservative.