Recent physiological, pharmacological and anatomical studies provide evidence that one of the main roles of the endocannabinoid system in the brain is the regulation of gamma-aminobutyric acid (GABA) and glutamate release. This article aims to review this evidence in the context of its implications for pain. We first provide a brief overview of supraspinal regulation of nociception, followed by a review of the evidence that the brain's endocannabinoid system modulates nociception. We look in detail at regulation of supraspinal GABAergic and glutamatergic neurons by the endocannabinoid system and by exogenously administered cannabinoids. Finally, we review the evidence that cannabinoid-mediated modulation of pain involves modulation of GABAergic and glutamatergic neurotransmission in key brain regions.