The therapeutic activation of antitumour immunity by immune checkpoint inhibitors (ICIs) is a significant advance in cancer medicine, not least due to the prospect of long-term remission. However, many patients are unresponsive to ICI therapy and may experience serious side effects; companion biomarkers are urgently needed to help inform ICI prescribing decisions. We present the IMMUNETS networks of gene coregulation in five key immune cell types and their application to interrogate control of nivolumab response in advanced melanoma cohorts. The results evidence a role for each of the IMMUNETS cell types in ICI response and in driving tumour clearance with independent cohorts from TCGA. As expected, ‘immune hot’ status, including T cell proliferation, correlates with response to first-line ICI therapy. Genes regulated in NK, dendritic, and B cells are the most prominent discriminators of nivolumab response in patients that had previously progressed on another ICI. Multivariate analysis controlling for tumour stage and age highlights CIITA and IKZF3 as candidate prognostic biomarkers. IMMUNETS provide a resource for network biology, enabling context-specific analysis of immune components in orthogonal datasets. Overall, our results illuminate the relationship between the tumour microenvironment and clinical trajectories, with potential implications for precision medicine.