This study aimed to explore the mechanism of Xiaoyao San(XYS) in the treatment of three diseases of liver depression and spleen deficiency, ie, depression, breast hyperplasia, and functional dyspepsia, and to provide a theoretical basis for the interpretation of the scientific connotation of "treating different diseases with the same method" of traditional Chinese medicines. Traditional Chinese medicine systems pharmacology database and analysis platform(TCMSP) was used to screen the active components of XYS which underwent principal component analysis(PCA) with the available drugs for these three diseases to determine the corresponding biological activities. The targets of XYS on depression, breast hyperplasia, and functional dyspepsia were obtained from GeneCards, TTD, CTD, and DrugBank databases. Cytoscape was used to plot the "individual herbal medicine-active components-potential targets" network. The resulting key targets were subjected to Kyoto encyclopedia of genes and genomes(KEGG) pathway analysis and gene ontology(GO) enrichment analysis. A total of 121 active components of XYS and 38 common targets in the treatment of depression, breast hyperplasia, and functional dyspepsia were collected. The key biological pathways were identified, including advanced glycation and products(AGEs)-receptor for advanced glycation and products(RAGE) signaling pathway in diabetic complications, HIF-1 signaling pathway, and cancer-related pathways. The key targets of XYS in the treatment of depression, breast hyperplasia, and functional dyspepsia included IL6, IL4, and TNF, and the key components were kaempferol, quercetin, aloe-emodin, etc. As revealed by the molecular docking, a strong affinity was observed between the key components and the key targets, which confirmed the results. The therapeutic efficacy of XYS in the treatment of diseases of liver depression and spleen deficiency was presumedly achieved by reducing the inflammatory reactions. The current findings are expected to provide novel research ideas and approaches to classify the scientific connotation of "treating different diseases with the same method" of Chinese medicines, as well as a theoretical basis for understanding the mechanism of XYS and exploring its clinical applications.