A huge peaceful protest in Hong Kong against controversial plans to allow extraditions to the Chinese mainland descended into violence early on Monday as police fought running battles with small pockets of demonstrators.
Organizers said more than a million people took part in the Sunday march - the largest protest since the Hong Kong's 1997 handover to China - confronting the city's pro-Beijing leadership with a major political crisis.
The city government is pushing a bill through the legislature that would allow extraditions to any jurisdiction with which it does not already have a treaty - including mainland China.
The proposals have sparked an outcry and birthed an opposition that unites a wide cross-section of the city.
Sunday saw huge crowds march in blazing summer heat through the cramped streets of the financial hub's main island in a noisy, colorful demonstration calling on the government to scrap its planned extradition law.
The march passed without incident.
But shortly after midnight violence flared as police moved to clear protesters who had vowed to stay overnight outside parliament. Demonstrators hurled bottles and used metal barricades as police moved in moments after the protest permit expired.
Officers used pepper spray hoses to push the crowds back, who shouted We have a right to protest!
Skirmishes continued overnight as protesters and police played cat and mouse in the nearby streets.
The scenes were reminiscent of 2014 when police used tear gas to disperse pro-democracy demonstrators outside the same building, sparking public anger and setting off two months of demonstrations that took over key intersections of the international finance hub.
Just hours earlier protesters had been celebrating the huge turnout, hoping it would prompt the government into rethinking the law.
For more than six hours on Sunday dense crowds snaked their way through the city chanting Scrap the evil law! and Oppose China extradition!
Police, who historically give much lower figures than organizers, put the peak crowd size at 240,000 - still their second highest estimate for attendance at a protest since handover.
The city's population is around 7.3 million and the organizer figure for Sunday's protest outstripped 2003, when an estimated half a million demonstrators forced the government to shelve a deeply unpopular national security law.
Ignoring the protests could fuel public anger or prompt more widespread clashes, with organizers saying they would upgrade their actions if the government did not drop the bill.
But backtracking by Lam might embolden opponents and anger Beijing. Several senior Communist Party leaders in China have voiced support for the bill.
In a statement late Sunday the government showed no sign of compromise, urging legislators to proceed with the bill's second reading on Wednesday.
Opposition to extradition has come from a wide political and social spectrum.
Lawyers, business groups, activists, journalists and western powers have all voiced alarm.
Hong Kong's leaders say the law is needed to plug loopholes and stop the city being a bolt hole for mainland fugitives.
They say dissidents and critics will not be extradited and have urged the bill's quick passage to extradite a Hong Kong man who is wanted in Taiwan for murdering his girlfriend.
But critics fear the law would entangle people in China's opaque and politicized court system and say the government is using the Taiwan case as a Trojan Horse.