In this study, we constructed a model using a Cox proportional hazards model based on the expression of eight immune-related genes that were associated with prognosis in prostate cancer: EDNRB, ANGPTL2, TNFSF15, TNFRSF10D, EDN2, BMP2, NLRP14, and PLK1. We then identified associations between risk scores calculated with the model, tumor microenvironment characteristics, and immune cell infiltration. Prostate cancer patients in the high score group had poorer prognoses, and validation with the external GSE54460 dataset confirmed that the scoring model predicted biochemical recurrence with AUC values of 0.749 at 1 year, 0.804 at 3 years, and 0.774 at 5 years. Proportions of infiltrated M2 macrophages and regulatory T cells were increased in the high risk group, while CD8+ T cells were increased in the low risk group. Network analysis revealed that PLK1 may be a key regulator of the immune-suppressive microenvironment in prostate cancer. Double immunofluorescence labeling of a prostate cancer tissue microarray indicated that PLK1 expression correlated positively with numbers of infiltrating macrophages. These results indicate that an immune- related, gene-based risk score effectively reflects immune microenvironment characteristics and predicts prognosis in prostate cancer.