Ecuador’s president got a resounding victory on Sunday in a referendum that he touted as a way to crack down on criminal gangs behind a spiralling wave of violence.

An official quick count showed that Ecuadorians overwhelmingly voted “yes” to all nine questions focused on tightening security measures, rejecting only two more controversial economic proposals.

The quick count was announced by the head of the Electoral National Council, Diana Atamaint.

It confirmed a private exit poll released hours before that indicated a resounding victory and sign of support for Ecuador’s President Daniel Noboa.

Ecuador Referendum
Soldiers patrol in the Carapungo neighbourhood of Quito, Ecuador (Dolores Ochoa/AP)

Among the measures approved are Mr Noboa’s call to deploy the army in the fight against the gangs, to loosen obstacles for extraditing accused criminals and to lengthen prison sentences for convicted drug traffickers.

Ecuador was traditionally one of South America’s most peaceful countries, but it has been rocked in recent years by a wave of violence, much of it spilling over from neighbouring Colombia, the world’s largest producer of cocaine.

Last year, the country’s homicide rate shot up to 40 deaths per 100,000 people, one of the highest in the region.

Mr Noboa has rallied popular support by confronting the gangs head on. That task became more urgent in January when masked gunmen, some on orders from imprisoned drug traffickers, terrorised residents and took control of a television station while it was live on the air in an unprecedented show of force.

Following the rampage, the 36-year-old president decreed an “internal armed conflict”, enabling him to use emergency powers to deploy the army in pursuit of about 20 gangs now classified as “terrorists”.

The referendum, in which 13 million Ecuadorians were called to vote, contained measures to extend those powers and put them on firmer legal ground.

Some of the measures approved imply changes to Ecuador’s constitution, but because they were previously endorsed by the Constitutional Court, Mr Noboa only needs to publish them in the official gazette to go into effect.

Ecuador Security Referendum
An Air Force soldier votes in the referendum (Dolores Ochoa/AP)

Some of those initiatives are the ones related to the use of the army and extradition.

For the changes that require changing some general laws, the president will have to send a reform proposal to the Assembly, which will have 60 days to process them.

Mr Noboa, ahead of the final tally, celebrated the results. “We’ve defended the country,” he said in a message posted on social media.

“Now we will have more tools to fight against the delinquent and restore peace to Ecuador’s families.”

Mr Noboa’s law and order rhetoric recalls the policies of El Salvador’s wildly popular president, Nayib Bukele, a fellow millennial, and could give him a boost politically as he prepares to run for re-election next year.

Mr Noboa, is serving the final 18 months of a presidential term left vacant when fellow conservative Guillermo Lasso resigned amid a congressional investigation into allegations of corruption.

Mr Noboa was elected following a shortened but bloody campaign that saw one of his top rivals brazenly assassinated while campaigning.