The results of this study showed that after treatment, the CD4+ and CD4/CD8 ratios of the experimental group were higher than those of the control group, and the CD8+ levels were lower than that of the control group (P < 0.05), suggesting that mesalazine plus somatostatin and bifid triple viable capsules can effectively regulate the immune function of ulcerative colitis patients. Here, CD4 is linked to ulcerative colitis.