Cannabidiol, a major component of marijuana, protects nerves, and exerts antispasmodic, anti-inflammatory and anti‑anxiety effects. In the current study, the protective effect of cannabidiol was observed to prevent hydrogen peroxide (H2O2)‑induced apoptosis, inflammation and oxidative stress in nucleus pulposus cells. Nucleus pulposus cells were isolated from rats and cultured in vitro, and H2O2 was used to construct the nucleus pulposus cell model. Cell viability of the nucleus pulposus cells was assessed using a 3‑(4,5-dimethylthiazol-2-yl)-2,5‑diphenyltetrazolium bromide assay. The ratio of apoptotic cells, and caspase‑3 or cyclooxygenase‑2 (COX‑2) mRNA expression was analyzed by annexin V‑fluorescein isothiocyanate/propidium‑iodide staining and reverse transcription‑quantitative polymerase chain reaction, respectively. The quantities of interleukin (IL)‑1β and interleukin‑6 were measured using a series of assay kits. B-cell lymphoma 2 (Bcl‑2) and inducible nitric oxide synthase (iNOS) protein expression levels were analyzed using western blotting. The present study identified that cannabidiol enhanced cell viability and reduced apoptosis in H2O2‑treated nucleus pulposus cells in vitro using a lumbar disc herniation (LDH) model. In addition, cannabidiol reduced caspase‑3 gene expression and augmented the Bcl‑2 protein expression levels in the nucleus pulposus cells following H2O2 exposure. Pre‑treatment with cannabidiol suppressed the promotion of COX‑2, iNOS, IL‑1β and IL‑6 expression in the nucleus pulposus cells following H2O2 exposure. Taken together, these results suggest that cannabidiol potentially exerts its protective effect on LDH via the suppression of anti‑apoptosis, anti‑inflammation and anti‑oxidative activities in nucleus pulposus cells.