Primary nonresponse to infliximab in patients with ulcerative colitis (UC) is common. However, there are currently no effective biomarkers for this prediction. This study aimed to identify potential predictors for precision anti-tumor necrosis factor-alpha treatment in patients with UC. Four GPL570 datasets (GSE14580, GSE12251, GSE23597, and GSE16879) were included in this study. Sixty-nine differentially expressed genes (DEGs) were identified, while 67 were up-regulated and two were down-regulated by comparing the gene expression in response samples with the nonresponse samples. Gene Ontology analysis showed that DEGs were mostly enriched in neutrophil-mediated immunity, neutrophil activation, neutrophil activation involved in the immune response, neutrophil degranulation, and leukocyte migration. Kyoto Encyclopaedia of Genes and Genomes analysis indicated that these DEGs were mostly enriched in cytokine-cytokine receptor interactions and interleukin (IL)-17 signalling pathways. After protein-protein interaction network analysis, verification by test set, and confirmation of clinical UC samples, S100 calcium-binding protein A8 (S100A8), S100A9, triggering receptor expressed on myeloid cells 1 (TREM1), toll-like receptor 2 (TLR2), IL1B, and formyl peptide receptor 1 (FPR1) were identified as the hub genes. We found that the immune cell composition in the intestinal tissues of UC patients with primary nonresponse included naïve CD4+ T cells, memory resting CD4+ T cells, resting natural killer cells, resting dendritic cells, activating dendritic cells, eosinophils, and neutrophils. Among these, neutrophils showed the most significant differences. In addition, all six potential predictors were significantly associated with the neutrophil count. Our study identified six potential biomarkers, namely S100A8, S100A9, TREM1, TLR2, IL1B, and FPR1, and one type of immune cell, neutrophils, between UC patients with response and primary nonresponse to infliximab. We speculated that changes in the expression of these six potential biomarkers combined with changes in the activity or local quantity of neutrophils might help predict primary nonresponse to infliximab in patients with UC.