In summary, according to the results of our ML model, the immune cell profiles of patients with NPC are characterized by differences in monocytes, PD‐1+ CD4 T cells, memory B cells, CTLA4+ CD4 Treg cells and PD‐1+ CD8 T cells relative to those of non‐NPC patients. The gene discussed is CD8A; the disease is nasopharyngeal carcinoma.