Among the various factors involved in the development of gastric cancer (GC), infectious agents are one of the most important causative inducers. This study aimed to investigate the possible role of EBV gene expression on SHP1 methylation in co-infection with Helicobacter pylori in patients with GC. Formalin-fixed paraffin-embedded samples were obtained from 150 patients with gastrointestinal disorders. The presence of the H. pylori and EBV genome were examined by PCR. The expression level of viral gene transcripts and methylation status of the SHP1 cellular gene was assessed by quantitative real-time PCR and methyl-specific PCR. EBV and H. pylori coinfection were reported in 5.6% of patients. The mean DNA viral load was significant in patients coinfected with cagA-positive H. pylori (P= 0.02). The expression of BZLF1 and EBER was associated with GC. Also, the expression level of BZLF1in GC tissues was significantly higher in coinfection (P = 0.01). SHP1 methylation frequency was higher in the GC group than in the control group (P = 0.04). The correlation between the methylation rate and the H. pylori infection was highly significant (P<0.0001). The strongest positive correlation was observed in GC specimens between SHP1 methylation and H. pylori cagA-positive strains (p= 0.003). Our results suggested that cagA might involve in the elevation of EBV lytic gene expression and SHP1 methylation, and the development of gastric cancer. Understanding the mechanism of EBV H. pylori - cagA + coinfection, as well as host epigenetic changes, can play an important role in diagnosing and preventing gastric cancer.