BackgroundTongxieyaofang (TXYF) was a traditional Chinese medicine (TCM) formula for the treatment of diarrhea with liver stagnation and spleen deficiency syndrome, but the potential targets and mechanisms have not been fully clarified. This study aims to explore the potential mechanisms of TXYF in alleviating diarrhea using network pharmacology and full-length 16S rRNA gene sequencing.MethodsNetwork pharmacology was applied to identify bioactive compounds and potential targets involved in the role of TXYF in alleviating diarrhea. Meanwhile, a model of diarrhea with liver stagnation and spleen deficiency syndrome was constructed by intragastric administration of Folium senna extract combined with restraint and tail pinch stress. The effect of TXYF on intestinal mucosal microbiota of diarrhea mice was analyzed by full-length 16S rRNA gene sequencing.ResultsNetwork pharmacology analysis showed that kaempferol, wogonin, naringenin, and nobiletin were compounds associated with the efficacy of TXYF. TXYF may alleviate diarrhea via multiple BPs and pathways, including TNF signaling pathway, IL-17 signaling pathway, and Toll-like receptor signaling pathway, which are involved in TCM-gut microbiota-host interactions. Then, we found that TXYF administration reshaped the diversity and composition of the intestinal mucosal microbial community of diarrhea mice. Lactobacillus, primarily Lactobacillus johnsonii, was enriched by the administration of TXYF. After TXYF administration, the abundance of Lactobacillus, particularly Lactobacillus johnsonii, was enriched.ConclusionOral administration of TXYF may alleviate diarrhea through remodeling intestinal mucosal microbiota. Promoting the colonization of beneficial commensal bacteria in the intestinal mucosa through gut microbiota-host interactions may be a potential mechanism of TXYF in the treatment of diarrhea.