Objectives:Community-acquired pneumonia(CAP)is a leading cause of hospitalization and death in children.The present study mainly aimed to screen out immune-related genes in CAP.Methods:CAP data were retrieved from GEO online database.The immune-related genes were identified using bioinformatics method,and their function and relationship with immune cells were further investigated.Results:The differential expressed genes between CAP group and normal group were mainly related to antigen processing and presentation,ribosome,apoptosis and inflammatory response.Moreover,a total of 10 key immune-related genes were selected using WGCNA and PPI analysis,including IL4R,FGR,CCR3,CCR1,ARG1,CEBPB,IL17RA,NFKBIA,PPARG,and NCF4.The expression levels of these genes were significantly correlated with the infiltration level of immune cells.Conclusion:The key genes identified from this study might play important roles in the immune response of CAP.