People who try to quit smoking go to great lengths. But the key to quitting might be found in a drug that’s illegal in much of the world. At least Matthew Johnson of Johns Hopkins University thinks so, after testing a therapy with double the success rate of other methods.

The drug in question is psilocybin, the active chemical in magic mushrooms. Research involving psilocybin and LSD in the 1950s and 1960s to treat addiction showed promise, until the drugs escaped the lab and became popular with the psychedelic set. After their use was criminalized, research ground to a halt.

However, in recent years, scientists have been trying to reopen research into these drugs. In 2008, Johnson co-authored human safety guidelines to promote the study of hallucinogens. Since then, as many as 460 sessions involving the use of psilocybin have been conducted at Johns Hopkins alone.

The most notable recent success came in a smoking-cessation program, a 15-week plan that features four sessions of cognitive behavioral therapy (CBT) and three sessions of psilocybin doses.

In CBT, psychologists ask smokers to reflect on their addiction. A key part of this is to memorize a personal mantra that captures why they want to quit.

AP Photo/Seth Wenig Magic pill?

For their dose of the drug, participants are taken to an incense-filled room where they are each given a wooden goblet containing a psilocybin pill. Once the pill is taken, researchers cover patients’ eyes and put on headphones. They are then asked to repeat their personal mantra.

The aim is to give the participants a mystical experience in a strictly controlled setting. ”We usually discourage them from getting too chatty because it can be really easy to get absorbed in the interesting sensory things that are going on,” Albert Garcia-Romeu, Johnson’s colleague, told the BBC. “We try to encourage them to go inward and that’s really where a lot of the important work happens.”

It may sound a bit wooly, but in one small study in 2014 it was shown to work. In a six-month follow-up after treatment, 12 out 15 participants had not smoked for at least a week. By that measure, the result was twice as successful as other cessation therapies, which have a success rate of less than than 35%.

Johnson and his team can’t explain fully why their therapy works, but they believe that the key is probably purely psychological. The drug is not known to affect nicotine receptors, but they can’t rule out that it may have some indirect effect.

Psilocybin has also been used to treat anxiety in cancer patients, but more widespread use will need to overcome taboos before it gets anywhere near the mainstream. A large-scale study should be conducted to confirm the intriguing findings on its effect on smokers.

Thomas Insel, director of the US government’s National Institute of Mental Health, told the BBC that the lack of a “clear regulatory framework” for the use of hallucinogens in psycotherapy will keep them from becoming widely available as medicines any time soon. “But that’s not a reason to avoid developing the therapies.”