Nivolumab improves the prognosis of non-small cell lung cancer (NSCLC) but can cause immune-related adverse events (irAEs). Reports have indicated longer progression-free survivals (PFSs) in patients with irAEs than in those without irAEs. We reported associations between programmed death ligand-1 (PD-L1) single nucleotide polymorphisms (SNPs) and PFS after nivolumab treatment. We hypothesized that adverse events might be associated with the SNPs of PD-L1. We analyzed data from 111 patients with NSCLC treated with nivolumab. The response rate was 14%, and the median PFS was 68 days. We found patients with the adverse event of low free tetraiodothyronine (fT4) had significantly longer PFSs than those without low fT4 (not reached vs 67 days; hazard ratio [HR], 0.297; P = 0.010). Moreover, median overall survival was longer in patients with low fT4 than those without low fT4 (not reached vs 556 days, HR, 0.139; P = 0.020). Patients with the T allele of rs1411262 (P = 0.0073) and with the A allele of rs822339 (P = 0.0204) developed low fT4. Patients with the T/T genotype had longer PFSs than with those with the C/T and C/C genotypes of rs1411262 (165 vs. 67 days, HR, 1.65; P = 0.040), and those with the A/A genotype had longer PFSs than those with the A/G and G/G genotypes of rs822339 (182 vs. 67 days, HR, 1.76; P = 0.025). In the patients with advanced NSCLC, low fT4 after nivolumab treatment was associated with significantly longer PFSs. The SNPs of PD-L1 may be associated with the adverse events of nivolumab.