The 1960s saw the height of psychedelia, a subculture that embraces the use of psychedelic drugs. And while there were many, many instances in which Tom Wolfe’s The Electric Kool Aid Acid Test could paint a good picture of what it was like — colorful lights, lots of noise, and school buses full of people high on acid blasting the Grateful Dead — there were others looking into the therapeutic potential of psychedelics. A psychologist and user of psychedelics himself, Dr. Timothy Leary was one of these people; he spent a few short years at Harvard University working on the Harvard Psilocybin Project. He believed that psilocybin, the active chemical in magic mushrooms, had the power to change people’s brains for the better. Fifty years later, scientists are beginning to realize Leary may have been on to something.

Psilocybin profoundly alters consciousness, rearranging the brain so that new connections between neurons are made, and accessing them becomes easier. This doesn’t occur randomly, but instead, the neurons assume a new order, which brings clarity and new perspectives on old and new thoughts. Those effects are then combined with what scientists have found to be activation in the area of the brain — the hippocampus and anterior cingulate cortex — responsible for emotion and dreaming. “People often describe taking psilocybin as producing a dreamlike state,” Robin Carhart-Harris, a researcher who studies psilocybin, told Reuters earlier this year. Meanwhile, with the activity in the emotion region of the brain working at full-force, the area that helps us find a sense of self-awareness (the ego) goes quiet.

These effects are gone within five to 10 hours, however, the enlightenment they bring is long-lasting. Studies have shown that the psilocybin in mushrooms may be an effective chemical for treating post-traumatic stress disorder, depression, and anxiety. In a 2011 study, researchers enlisted 12 participants suffering from an advanced stage of cancer, and diagnosed with acute stress disorder or anxiety disorder. After giving them either a small dose of psilocybin, niacin (it induces a mild psychological reaction), or a placebo, they found that those who took psilocybin alleviated some stress, as measured by the STAI anxiety subscale. These effects were consistent up to three months after treatment.

Smokers may also benefit from taking a magic mushroom here and there. In September, researchers from Johns Hopkins University found that 12 out of 15 smokers were able to quit while sitting in a room, tripping on psilocybin, and listening to calming music. Those whose experiences were the most profound were more likely quit, the researchers said. “The rates of quitting were so high, twice as high as what you typically see with the gold standard medication,” researcher Matthew Johnson told Bloomberg News.

Science is only beginning to unravel the mysteries that surround drug use as treatment for psychiatric conditions. In the past few years, studies have shown that other drugs, like LSD and MDMA, also offer some benefit despite sitting next to marijuana and psilocybin on the list of Schedule I substances. Offering them to patients in a controlled manner, like the Johns Hopkins researchers did, could be a good way to procure their benefit without risking the dangers associated with fully dosed drugs.