Abstract: Objective: To summarize and analyze the medication patterns and clinical experience of WANG Ruping in treating insomnia through data mining technology. Methods: Insomnia cases treated at WANG Ruping's Famous Traditional Chinese Medicine Physician Studio in Guangzhou Zengcheng District Hospital of Traditional Chinese Medicine from January 2023 to April 2024 were collected to establish a medical record database. Excel and IBM SPSS 24.0 software were used for principal component analysis and cluster analysis to explore medication characteristics and prescription patterns. Results: A total of 411 cases with 411 prescriptions containing 192 herbs were included, identifying 29 core herbs. Principal component analysis yielded 9 herb groups,while cluster analysis identified 6 herb groups. After removing redundant data, the following 8 core herb combinations were derived: Polygoni Multiflori Caulis;Lycii Fructus and Hordei Fructus Germinatus;wine-prepared Fructus Ligustri Lucidi,Ecliptae Herba,and Rehmanniae Radix Praeparata; Schisandrae Chinensis Fructus, Ophiopogonis Radix, and Pseudostellariae Radix; Pinelliae Rhizoma Praeparatum,and Prunellae Spica;Polygalae Radix Praeparata,and Acori Tatarinowii Rhizoma; Ostreae Concha,Os Draconis,and Margaritifera Concha;Mume Fructus,Curcumae Radix,and Platycladi Semen. Conclusion: WANG Ruping believes that a calm spirit leads to a healthy body. In the case of insomnia, the initial cause is often emotional stagnation, with yin damage as the root and a restless spirit as the manifestation. To treat insomnia effectively,it is essential to achieve a harmonious flow of qi and a balanced yin,which in turn will calm the spirit and facilitate sleep. Specifically,the treatment should prioritize nourishing yin and enriching blood,as well as resolving stagnation and calming the spirit. Commonly used Chinese herbs include Polygoni Multiflori Caulis; Lycii Fructus, Hordei Fructus Germinatus; wine-prepared Ligustri Lucidi Fructus, Ecliptae Herba, Rehmanniae Radix Praeparata; Schisandrae Chinensis Fructus, Ophiopogonis Radix, Pseudostellariae Radix; Mume Fructus, Curcumae Radix, and Platycladi Semen. When soothing the liver, take care to nourish yin; while nourishing yin, ensure to promote qi movement. In clinical treatment, it is advisable to skillfully use combinations of Chinese herbs such as Lycii Fructus with Hordei Fructus Germinatus,and Polygalae Radix Praeprata with Acori Tatarinowii Rhizoma to address symptoms of stomach disharmony and phlegm-turbidity. Additionally, emphasis should be placed on adjusting both the physiological and psychological states of patients to achieve the goal of improving sleep quality.