Xylo-oligosaccharides (XOS) enriched with high fractions of X2-X3 are regarded as an effective prebiotic for regulating the intestinal microflora. In this study, the original XOS solution was obtained from bamboo shoots through hydrothermal pretreatment under optimized conditions. Subsequently, enzymatic hydrolysis with endo-xylanase was performed on the original XOS solution to enhance the abundance of the X2-X3 fractions. The results demonstrated that hydrothermal pretreatment yielded 21.24% of XOS in the hydrolysate solution, and subsequent enzymatic hydrolysis significantly increased the proportion of the X2-X3 fractions from 38.87% to 68.21%. Moreover, the XOS solutions with higher amounts of X2-X3 fractions exhibited superior performance in promoting the growth of probiotics such as Bifidobacterium adolescentis and Lactobacillus acidophilus in vitro, leading to increased production of short-chain fatty acids. In the in vivo colitis mouse model, XOS solutions with higher contents of X2-X3 fractions demonstrated enhanced efficacy against intestinal inflammation. Compared with the colitis mice (model group), the XOS solution with higher X2-X3 fractions (S1 group) could significantly increase the number of Streptomyces in the intestinal microflora, while the original XOS solution (S2 group) could significantly increase the number of Bacteroides in the intestinal microflora of colitis mice. In addition, the abundances of Alcaligenes and Pasteurella in the intestinal microflora of the S1 and S2 groups were much lower than in the model group. This effect was attributed to the ability of these XOS solutions to enhance species diversity, reversing the imbalance and disorder within the intestinal microflora. Overall, this work highlights the outstanding potential of XOS enriched with high contents of X2-X3 fractions as a regulator of the intestinal microbiota and as an anti-colitis agent.