To investigate the correlation between the level of circulating vitamin D and the development of colorectal cancer (CRC) and to clarify the effect and mechanism of vitamin D on the development of CRC. Serum samples from 63 patients with CRC (CRC group) and 61 healthy volunteers (normal group) were collected. Azoxymethane+dextran sodium sulfate-induced CRC mouse model and dietary models with different doses of vitamin D were established to verify whether vitamin D supplementation could reverse the occurrence and development of CRC at the overall animal level. Intestinal barrier integrity and microbial defense response were evaluated by detection of intestinal flora and expression of related genes. In the clinical serum samples, compared with the normal group, the level of 25 (OH) D3 in the CRC group was relatively low (P<0.01), which was consistent with the clinical situation in mice. Vitamin D deficiency aggravated the deterioration of enteritis and intestinal cancer in CRC mice, whereas the overall condition of CRC mice improved after vitamin D supplementation. Vitamin D has a significant regulatory effect on the homeostasis of the intestinal flora, particularly in the regulation of intestinal probiotics, Akkermansia muciniphila-mediated colon barrier integrity. Vitamin D deficiency is closely related to the high incidence of CRC, and vitamin D supplementation can inhibit the occurrence and development of CRC. Vitamin D plays a role in the reversal of CRC mainly through the regulation of intestinal flora, especially the regulation of A.muciniphila-mediated colon barrier integrity.