An HLA variant confers protective immunity against COVID-19 through cross-reactive T cells induced by seasonal coronaviruses.