Abnormal G6PD activity (deficiency or overexpression) is closely associated with the pathogenesis of immune-related diseases: G6PD deficiency increases susceptibility to autoimmune diseases (<i>e.g.</i>, rheumatoid arthritis, systemic lupus erythematosus) and infectious diseases (<i>e.g.</i>, hepatitis, malaria, COVID-19) by inducing oxidative stress and immune cell dysfunction; in tumor immunity, G6PD dualistically promotes tumor cell proliferation while regulating anti-tumor immunity <i>via</i> modulating cytoxic D8<sup>+</sup> T cell exhaustion and macrophage polarization. This evidence concerns the gene G6PD and malaria.