Uruguay wants to make a "contribution to humanity" by legalizing marijuana but will backtrack if the "experiment" goes awry, President Jose Mujica told AFP in an exclusive interview.

Mujica said he sees his country as a potential test case for an idea slowly gaining steam across Latin America -- that the legalization and regulation of some drugs could sap the cartel violence devastating much of the region.

"Like any experiment, naturally, there are risks, and we have to understand that if they prove too much for us then we must backtrack. We do not have to be fanatics," Mujica said.

Last week a bill to have the government control and regulate marijuana sales and distribution was passed by the lower house of Uruguay's legislature.

The bill, which is backed by Mujica's leftist government, now awaits action by the Senate.

By putting the government in charge of the marijuana industry, which is estimated to be worth $30-40 million a year, the bill aims to curtail illegal trafficking and the violence that comes with it.

But opposition parties are against the idea and a poll released last week said so are 63 percent of Uruguayans.

Many opponents fear the legalization of cannabis would turn Uruguay into a pot tourism hub and encourage the use of stronger drugs.

Mujica counters that the current policies have failed, citing both the moral and financial expense of the war on drugs.

He estimates that Uruguay, a small country with just 3.3 million people, spends upwards of $80 million a year on combatting drugs but seizes just $4-5 million worth of contraband.

"As a business this would be a disaster, if you look at it purely from an economic standpoint," he said.

"From a moral point of view it's much worse, because the violence consumes a lot of people who have nothing to do with it," he said.

Uruguay is hardly the worst-hit by drug violence. In Mexico warring cartels have killed tens of thousands of people since 2006 and homicides have skyrocketed across much of Central America.

Guatemala's president has called for drug legalization, a vision shared by ex-presidents in Brazil, Mexico and Colombia but opposed by the United States and Mexico.

Mujica insists he does not want to totally liberalize marijuana, but merely bring it under strict official control, adding that he would be in favor of tough prison sentences for anyone cultivating unregistered cannabis.

Mujica also says he is not defending marijuana use or ignoring the problem of drug addiction. He declined to say whether he would eventually consider the legalization of harder drugs.