Human endocannabinoid systems modulate multiple physiological processes mainly through the activation of cannabinoid receptors CB1 and CB2. Their high sequence similarity, low agonist selectivity, and lack of activation and G protein-coupling knowledge have hindered the development of therapeutic applications. Importantly, missing structural information has significantly held back the development of promising CB2-selective agonist drugs for treating inflammatory and neuropathic pain without the psychoactivity of CB1. Here, we report the cryoelectron microscopy structures of synthetic cannabinoid-bound CB2 and CB1 in complex with G(i), as well as agonist-bound CB2 crystal structure. Of important scientific and therapeutic benefit, our results reveal a diverse activation and signaling mechanism, the structural basis of CB2-selective agonists design, and the unexpected interaction of cholesterol with CB1, suggestive of its endogenous allosteric modulating role.