Chang-Kang-Fang formula (CKF), a multi-herb traditional Chinese medicine, has been used in clinical settings to treat irritable bowel syndrome (IBS). Recent studies show that 5.0 g/kg/d CKF can alleviate the symptoms of IBS rats by modulating the brain-gut axis through the production of brain-gut peptides (BGPs), thus relieving pain, and reversing the effects of intestinal propulsion disorders. However, the exact mechanisms underlying the therapeutic effects of CKF in IBS remain unclear. The microbiota-gut-brain axis (MGBA) is central to the pathogenesis of IBS, regulating BGPs, depression-like behaviors, and gut microbiota. Given that CKF ameliorates IBS the MGBA, we performed metabolomic analyses, evaluated the gut microbiota, and system pharmacology to elucidate the mechanisms of action of CKF. The results of intestinal tract motility, abdominal withdrawal reflex (AWR), sucrose preference test (SPT), and the forced swimming test (FST) showed that the male Sprague-Dawley rats subjected to chronic acute combining stress (CACS) for 22 days exhibited altered intestinal motility, visceral hypersensitivity, and depression-like behaviors. Treatment of IBS rats with CKF normalized dysfunctions of CACS-induced central and peripheral nervous system. CKF regulated BDNF and 5-HT levels in the colon and hippocampus as well as the expressions of the related BGP pathway genes. Moreover, the system pharmacology assays were used to assess the physiological targets involved in the action of CKF, with results suggesting that CKF putatively functioned through the 5-HT-PKA-CREB-BDNF pathway. LC-MS-based metabolomics identified the significantly altered 5-HT pathway-related metabolites in the CKF treatment group, and thus, the CKF-related signaling pathways were further examined. After pyrosequencing-based analysis of bacterial 16S rRNA (V3 + V4 region) using rat feces, the Lefse analysis of gut microbiota suggested that CKF treatment could induce structural changes in the gut microbiota, thereby regulating it by decreasing , and the F-B ratio while increasing the levels of . Furthermore, the integrated analysis showed a correlation of CKF-associated microbes with metabolites. These findings showed that CKF effectively alleviated IBS, which was associated with the altered features of the metabolite profiles and the gut microbiota through a bidirectional communication along the microbiota-gut-brain axis.