Chemotherapy resistance eventually develops in patients with gastric cancer (GC). Intra-tumoral heterogeneity (ITH) refers to the intercellular genetic variations and phenotypic diversity that affect responses to drug therapy. We measured ITH using mutant-allele tumor heterogeneity (MATH) derived from whole-exome sequencing data of patients with GC in The Cancer Genome Atlas (TCGA) database. The study included 385 patients from the TCGA database with available data regarding gastrectomy, survival, and whole-exome sequencing. Further analysis was performed in 171 GC patients with available data regarding adjuvant chemotherapy. Multiple factor analysis showed that MATH was an independent predictor of OS (hazard ratio [HR], 1.432; 95% confidence interval [CI], 1.073–1.913; P = 0.015) in patients with GC. Moreover, MATH was also an independent predictor of OS among the 171 GC patients who received adjuvant chemotherapy (HR, 2.016; 95% CI, 1.236–3.289; P = 0.005). Pathway enrichment and immune cell analyses revealed significantly higher infiltration by 20 types of immune cells in the low/intermediate group, compared to the group with high MATH scores. In conclusion, low/intermediate MATH scores predicted longer OS, when compared to those with high MATH scores. The immune response was obviously upregulated in patients with GC and low/intermediate MATH scores.