Ecstasy is methylenedioxymethamphetamine, or MDMA for short, which is a synthetic, psychoactive (mind-altering) drug with hallucinogenic and amphetamine-like properties.
In this study, the people taking the drug rated the hallucinogenic experience as "stressful" at some times but "psychologically and spiritually uplifting" - describing encounters with past lives, faraway planets, and communing with deities.