Ayahuasca is the Quechua name for a tea obtained from the vine Banisteriopsis caapi, and used for ritual purposes by the indigenous populations of the Amazon. The use of a variation of the tea that combines B. caapi with the leaves of the shrub Psychotria viridis has experienced unprecedented expansion worldwide for its psychotropic properties. This preparation contains the psychedelic 5-HT2A receptor agonist N,N-dimethyltryptamine (DMT) from P. viridis, plus β-carboline alkaloids with monoamine-oxidase-inhibiting properties from B. caapi. Acute administration induces a transient modified state of consciousness characterized by introspection, visions, enhanced emotions and recollection of personal memories. A growing body of evidence suggests that ayahuasca may be useful to treat substance use disorders, anxiety and depression. Here we review the pharmacology and neuroscience of ayahuasca, and the potential psychological mechanisms underlying its therapeutic potential. We discuss recent findings indicating that ayahuasca intake increases certain mindfulness facets related to acceptance and to the ability to take a detached view of one's own thoughts and emotions. Based on the available evidence, we conclude that ayahuasca shows promise as a therapeutic tool by enhancing self-acceptance and allowing safe exposure to emotional events. We postulate that ayahuasca could be of use in the treatment of impulse-related, personality and substance use disorders and also in the handling of trauma. More research is needed to assess the full potential of ayahuasca in the treatment of these disorders.