T cell inhibitory mechanisms prevent autoimmune reactions, while cancer immunotherapy aims to remove these inhibitory signals. Chronic ultraviolet (UV) exposure attenuates autoimmunity through promotion of poorly understood immune-suppressive mechanisms. Here we show that mice with subcutaneous melanoma are not responsive to anti-PD1 immunotherapy following chronic UV irradiation, given prior to tumor injection, due to the suppression of T cell killing ability in skin-draining lymph nodes. Using mass cytometry and single-cell RNA-sequencing analyzes, we discover that skin-specific, UV-induced suppression of T-cells killing activity is mediated by upregulation of a Ly6ahigh T-cell subpopulation. Independently of the UV effect, Ly6ahigh T cells are induced by chronic type-1 interferon in the tumor microenvironment. Treatment with an anti-Ly6a antibody enhances the anti-tumoral cytotoxic activity of T cells and reprograms their mitochondrial metabolism via the Erk/cMyc axis. Treatment with an anti-Ly6a antibody inhibits tumor growth in mice resistant to anti-PD1 therapy. Applying our findings in humans could lead to an immunotherapy treatment for patients with resistance to existing treatments.