JAKARTA - President Joko Widodo has issued a shoot-to-kill order against drug dealers and traffickers, especially foreign ones, as he called for tougher action in Indonesia’s war on drugs.

"The police and TNI (military) have been firm, especially when dealing with foreign drug traffickers entering the country," said the President, popularly known as Jokowi. "If they resist arrest, just gun them down, show no mercy."

Mr Joko, who was speaking at an event in Jakarta on Friday (July 21 ) night, also warned that the drug situation has put the country in a national emergency.

But his comments have drawn comparisons to his Philippine counterpart Rodrigo Duterte, who has been criticised for his drug war killings, which have left thousands dead.

Indonesia has one of the world's toughest drugs laws, and remains one of 33 countries that still use capital punishment for drug-related offences.

Since the country lifted a four-year moratorium on the death penalty in 2013, 18 people - all drug traffickers - have been sent to the firing squad.

Among the 15 foreigners executed were Andrew Chan and Myuran Sukumaran, both of whom were part of the Bali Nine, a name given to a group of nine Australians convicted for attempting to smuggle 8.3 kg of heroin in April 2005.

Indonesia has struggled to contain the drug problem, with officials estimating that there are at least 1.2 million drug-abusers in the country.

Ecstasy, heroin, marijuana, and methamphetamine, better known as crystal meth, are the drugs of choice for substance abusers in Indonesia, similar to those preferred by drug users in many other countries in the region.

On July 13, a suspected drug trafficker from Taiwan was shot dead by Indonesian police as he tried to escape.

Lin Ming Hui was one of four Taiwanese men found in Banten, a city near the capital Jakarta,with one tonne of crystal meth, better known by its Indonesian street-name 'Shabu-shabu'.

Indonesian National Police chief Tito Karnavian said following the incident that he had ordered his officers not to hesitate when having to use their firearms against drug dealers who resist arrest.

General Tito, citing the example of the Philippines, said he believes the death penalty was an effective way to combat drug dealers, despite the controversies surrounding capital punishment.

"From the practice in the field, we see that when we shoot at drug dealers they go away," he added, referring to President Duterte's shoot-to-kill order to the Philippine National Police. "So if such a policy were implemented in Indonesia, we believe that the number of drug traffickers and users in our beloved country would drop drastically."

His remarks, however, drew a strong response from some observers such as Human Rights Watch deputy director for Asia, Mr Phelim Kine.

Mr Kine said General Tito should "denounce the Philippines' war on drugs for what it truly is - a brutal, unlawful assault on the rule of law, human rights, and basic decency that has targeted some of the country's poorest, most marginalised citizens".

He also called on Mr Joko to send a clear message to the police that efforts to address the complex problems of drugs and criminality require the security forces to respect everyone's basic rights, not demolish them.

He added: "Duterte's drug war is not about 'capital punishment' - a judicially imposed sentence after a criminal trial - but a police-led summary killing campaign that that has killed more than 7,000 Filipinos since Duterte took office."