Gastric cancer is the most common malignant tumor of the digestive system. The progression from gastritis to gastric cancer may be related to genetic factors, but the specific molecular mechanism remains unclear. Therefore, an in-depth study of the molecular mechanism of gastritis and gastric cancer is significant. We downloaded two gene profiles, GSE2669 and GSE116312, from the Gene Expression Omnibus (GEO) database. This study aims to apply bioinformatics technology to mine differentially expressed genes (DEGs), DEGs annotation, protein-protein interaction (PPI) network creation, and hub gene identification and expression between gastric cancer patients and gastritis patients. Overall survival analysis of hub genes, analysis by comparative toxicogenomics database for hub genes in gastric cancer, THBS2 and VCAN protein expression by immunohistochemistry for gastric cancer and gastritis as well as design of the biological process (BP) neural network was implemented. The MSLN, SPP1, THBS2, SPARC, FN1, IGFBP7, VCAN were up-regulated in gastric carcinoma samples, while FGA was down-regulated. The protein expression of THBS2 and VCAN in gastric cancer was significantly higher than that in gastritis. VCAN protein expression was positively associated with tumor invasion (P = 0.011) and HER2 overexpression (P = 0.031). Strong correlation among THBS2, VCAN, and gastric cancer based on the BP neural network. THBS2 and VCAN may be potential targets for improving gastric cancer patients' diagnosis and clinical efficacy.