In this paper, the mechanism of action of lily against gastric cancer was analysed by network pharmacology. It was found that lily inhibited gastric cancer cells by inhibiting GSTP1, AHR, AURKB, AKR1C3, RORA, an d IL6 to regulate cell proliferation, leukocyte activation, c ell activation and other pathways. In addition, lily may fight against gastric cancer by promoting apoptosis and inhibiting cell proliferation. GSTP1, AHR, AURKB, AKR1C3, RORA, and IL6 were shown to be the main drug target s through the drug-disease-pathway. The high expression o f GSTP1, AHR, AURKB, AKR1C3, RORA, IL6 in gastric cancer tissues correlated with the mutation of gastric cancer tissues and the life span of the patients, and the high expression of GSTP1, AHR, AURKB, AKR1C3, RORA, I L6 was detrimental to the survival of the patients. Conclusion shows that lily plays a role in inhibiting gastric cancer cells by suppressing the expression of GSTP1, AHR, A URKB, AKR1C3, RORA, and IL6.