Indonesia's parliament has shelved planned changes to electoral laws after protesters in the capital set fires and faced down tear gas and water cannon over legislation they say would weaken opponents of the outgoing president and his successor.
The legislature, dominated by supporters of outgoing President Joko Widodo and his successor Prabowo Subianto was scheduled to vote to reverse changes to election laws made by the constitutional court, a ruling that effectively reopened a chance for a vocal government critic to run in regional elections.
Parties backing Prabowo had earlier this week rallied behind a single candidate for the influential post of Jakarta governor, killing off chances of the president-elect's rival Anies Baswedan from running.
Anies at the time needed the backing from a party or a coalition of parties with at least 20 per cent of seats in the local parliament, under rules for regional elections in place since 2016.
But Tuesday's Constitutional Court ruling had lowered the threshold to under 10 per cent, giving Anies a chance to be nominated by the only party that has not named a candidate, PDIP.
The Indonesian parliament had sought to return to the previous threshold, contradicting the country's highest court in a move critics said would favour the outgoing president and his family - and the incoming government - as they consolidate power and freeze out any opposition.
"This is a republic. It's a democracy but if its leadership is decided by one person, or an oligarchy, we can't accept that," 29-year-old teacher Afif Sidik said.
On Thursday, deputy parliament speaker Sufmi Dasco Ahmad told Reuters that deliberations would be resumed by the incoming parliament, meaning there would be no change for this year's regional elections, scheduled for November.
Student protesters rallied outside parliament in Jakarta over plans for election changes. (AP PHOTO)
That means Anies will be able to seek the Jakarta governor's office if PDIP nominates him.
The parliament decision came as security forces fired tear gas and water cannons as protesters breached and set ablaze part of the gates of parliament while demonstrations broke out across the country against the election law changes.
Thousands gathered outside parliament to protest against the move to reverse the court ruling, carrying signs accusing Widodo - widely known as "Jokowi" - of nepotism and destroying democracy.
Others carried a mock guillotine bearing his face.
The now-postponed legislation would also have paved the way for Jokowi's youngest son, Kaesang Pangarep, 29, to run in elections in Central Java this November by tweaking rules on age requirements.
The protests were sparked by a battle over which branch of government has ultimate jurisdiction in determining election rules, after the parliament had said it planned to ratify changes to the law on Thursday morning.
Legal experts and election analysts had warned the stand-off between parliament and the judiciary was pushing the country towards a constitutional crisis.