Background: The occurrence and development of Hepatic fibrosis (HF) are closely related to the gut microbial composition and alterations in host metabolism. Qijia Rougan decoction (QJ) is a traditional Chinese medicine compound utilized clinically for the treatment of HF with remarkable clinical efficacy. However, its effect on the gut microbiota and metabolite alterations is unknown. Therefore, our objective was to examine the impact of QJ on the gut microbiota and metabolism in Carbon tetrachloride (CCl4)-induced HF.Methods: 40% CCl4 was used to induce HF, followed by QJ administration for 6 weeks. Serum biochemical analyses, histopathology, immunohistochemistry, RT-PCR, 16S rRNA gene sequencing, and non-targeted metabolomics techniques were employed in this study to investigate the interventional effects of QJ on a CCl4-induced HF model in rats.Results: This study demonstrated that QJ could effectively ameliorate CCl4-induced hepatic inflammation and fibrosis. Moreover, QJ upregulated the expression of intestinal tight junction proteins (TJPs) and notably altered the abundance of some gut microbes, for example, 10 genera closely associated with HF-related indicators and TJPs. In addition, metabolomics found 37 key metabolites responded to QJ treatment and strongly associated with HF-related indices and TJPs. Furthermore, a tight relation between 10 genera and 37 metabolites was found post correlation analysis. Among them, Turicibacter, Faecalibaculum, Prevotellaceae UCG 001, and unclassified Peptococcaceae may serve as the core gut microbes of QJ that inhibit HF.Conclusion: These results suggest that QJ ameliorates hepatic inflammation and fibrosis, which may be achieved by improving intestinal tight junctions and modulating gut microbiota composition as well as modulating host metabolism.