Objective To investigate the effects of 5‑hydroxytryptophan (5‑HTP) sustained‑release formulation on spatial learning and memory in a chronic unpredictable mild stress (CUMS) mouse model, and to explore its potential molecular mechanisms. Methods Sixty‑six mice were randomly divided into six groups, with 11 mice in each group: normal control, model, 5‑HTP sustained‑release, fluoxetine, 5‑HTP sustained‑release+fluoxetine, and 5‑HTP immediate‑release groups. Except for the normal control group, mice in the remaining groups received random stress stimuli for 35 consecutive days to establish the CUMS model. On the day after modeling, the 5‑HTP sustained‑release group received drinking sterile water containing 5‑HTP (in concentration of 2 mg/mL, with intake of 300 mg/kg) and intragastric administration of sterile normal saline, the fluoxetine group received intragastric administration of fluoxetine hydrochloride solution (with intake of 3 mg/kg), the 5‑HTP sustained‑release+fluoxetine group received 5‑HTP‑containing drinking sterile water (in concentration of 2 mg/mL, with intake of 300 mg/kg) and intragastric administration of fluoxetine hydrochloride (with intake of 3 mg/kg), and the 5‑HTP immediate‑release group received intragastric administration of 5‑HTP solution (with intake of 100 mg/kg), whereas the normal control and model groups received intragastric administration of equal volumes of sterile normal saline. All treatments were administered daily for 30 days. Spatial learning and memory of various groups were evaluated using the Morris water maze test. Brain‑derived neurotrophic factor (BDNF) mRNA expression in hippocampal tissue was measured by real‑time fluorescent quantitative PCR. Expressions of protein related to the BDNF‑extracellular signal‑regulated kinase (ERK)‑cyclic AMP dependent response element‑binding protein (CREB) signaling pathway in the hippocampus were detected by Western blot. Immunohistochemistry was used to detect the positive cell counts of B‑cell lymphoma‑2 associated X protein (Bax), B‑cell lymphoma 2 (Bcl‑2), and Caspase‑3 in various groups in the hippocampal dentate gyrus and CA3 region. Results (1) The model group exhibited longer escape latency on the second, fourth, and fifth day of experiment, whereas slower average swimming speed on the first day of experiment, shorter target quadrant dwell time, and fewer platform‑crossing times compared with the normal control group (P<0.05). The 5‑HTP sustained‑release group interpreted shorter escape latency on the fourth and fifth day of experiment as compared with the model group, slower average swimming speed on the first, third and fifth day of experiment compared with the normal control group, slower average swimming speed on the second, third and fifth day of experiment as compared with the model group, whereas longer average swimming distance on the second day of experiment compared to the model group; in addition, it also yielded longer target quadrant dwell time, and more platform‑crossing times compared with the model group (P<0.05). The 5‑HTP sustained‑release+fluoxetine group depicted shorter escape latency on the fifth day of experiment compared with the model group, slower average swimming speed on the first and second day of experiment compared with the normal control group, slower average swimming speed on the second day of experiment as compared with the model group, whereas shorter average swimming distance on the second day of experiment compared to the model group; furthermore, it expressed longer target quadrant dwell time compared with the model and fluoxetine groups, while fewer platform‑crossing times as compared with the 5‑HTP sustained‑release group and the fluoxetine group (P<0.05). (2) BDNF mRNA and protein expressions in the hippocampus were lower in the model group than in the normal control group, whereas BDNF mRNA and protein expressions in hippocampal tissue of various drug administration groups were higher than those in the model group (P<0.05). (3) Compared with the normal control group, the model group exhibited reduced phosphorylated CREB (p‑CREB)/CREB and phosphorylated ERK (p‑ERK)/ERK ratios in the hippocampus (P<0.05). Various drug administration groups showed increased p‑CREB/CREB ratio in hippocampal tissue relative to the model group (P<0.05), whereas only the fluoxetine and 5‑HTP sustained‑release+fluoxetine groups indicated increased p‑ERK/ERK ratio compared with the model group (P<0.05). (4) Compared with the normal control group, the model group showed fewer Bcl‑2‑positive cells and more Bax‑positive cells in the hippocampal CA3 region and dentate gyrus (P<0.05), with no statistically significant difference in Caspase‑3‑positive cells between the normal control group and the model group (P>0.05). Various drug administration groups exhibited increased Bcl‑2‑positive cells and decreased Bax‑positive cells in these hippocampal regions compared with the model group (P<0.05). Additionally, the 5‑HTP immediate‑release group showed increased Caspase‑3‑positive cells in the hippocampal CA3 region and dentate gyrus compared with the model group (P<0.05). Conclusion 5‑HTP sustained‑release formulation can ameliorate CUMS‑induced spatial learning and memory impairment in mice, and its mechanism may involve upregulation of BDNF and CREB protein expressions in the hippocampus and inhibition of neuronal apoptosis.