Night sweats can occur independently or in association with a number of medical conditions and can significantly disrupt daily life. This study focuses on the treatment of primary night sweats. Despite the considerable interest in Danggui Liuhuang Tang (DGLHT), an effective traditional Chinese medicine formula, its mechanism of action remains unknown. There is also no existing literature on the subject. Network pharmacology and molecular docking techniques. Network pharmacology techniques were employed to identify 109 active ingredients and 808 potential targets of DGLHT, as well as 2385 targets associated with night sweating diseases. The screening process yielded 375 common targets shared between DGLHT and night sweating. These included the active ingredients baicalein, quercetin, huarangiin, and tetrahydroafrican antipyrine, and the core targets interleukin 6, serine/threonine protein kinase 1, tumor necrosis factor, GAPDH enzyme, and Src protein kinase were identified. The Kyoto Encyclopedia of Genes and Genomes enrichment analysis revealed that DGLHT exerts its therapeutic effects primarily by modulating the PI3K-Akt signaling pathway, neuroactive ligand-receptor interactions, lipid metabolism, and atherosclerosis pathways. Molecular docking revealed strong binding activity between the main active ingredients and their potential targets. The research identifies promising active ingredients and targets related to the effectiveness of DGLHT in controlling night sweats, thus contributing to the further exploration of potential therapeutics for this condition. In addition, the results of this experiment provide a basis for future research into night sweats.