Gastric cancer tissues had reduced CD3<sup>+</sup>T, CD3<sup>+</sup>CD4<sup>+</sup>T cells and M1 macrophage infiltration, increased M2 macrophages and CD14<sup>+</sup>monocytes; AKAP12 was positively correlated with monocytes. Here, CD4 is linked to gastric cancer.