The occurrence of intestinal diseases such as colon cancer is closely related to the intestinal flora. Lactobacillus fermentum is a gut probiotic that plays an important role in chronic intestinal inflammation and colon cancer. In the current study, we investigated the effect of Lactobacillus fermentum ZS40 on NF-κB signaling pathway of azomethane-dextran sulfate sodium (AOM-DSS) -induced colon cancer in mice. Animals were divided into control group (NC), AOM-DSS-induced model group (CRC), AOM-DSS plus high-dose Lactobacillus fermentum ZS40 (ZS40-H), AOM-DSS plus low-dose Lactobacillus fermentum ZS40 (ZS40-L), AOM-DSS plus Lactobacillus bulgaricus (BLA), and AOM-DSS plus sulfasalazine (SD)-treated group. Observation of animal physiological activity (body weight and defecation), biochemical measurements, histopathological examination of colon tissue, qPCR to evaluate the expression of inflammation-related genes, immunohistochemical analysis of CD34 and CD117, and Western blot analysis of NF-κB signaling pathway were performed. Compared with the CRC group, the ZS40-H, ZS40-L, BLA, and SD groups had decreased levels of colon cancer marker proteins CD34 and CD117, and the number of abnormal colonic lesions observed by colon histology decreased, while the ZS40-H group showed excellent results. In addition, all probiotic interventions showed weight loss effects. The expression of inflammatory stimulators TNF-α and IL-1β in the probiotic treatment group decreased; the expression of key proteins IκBα and p65 in the NF-κB signaling pathway also decreased, resulting in a decrease in the expression of the target protein Cox-2. Therefore, administration of Lactobacillus fermentum ZS40 as a probiotic can alleviate intestinal inflammation and prevent colon cancer in mice.