Microbial infections often precede the onset of autoimmunity. How infections trigger autoimmunity remains poorly understood. We investigated the possibility that infection might create conditions that allow the stimulatory presentation of self peptides themselves and that this might suffice to elicit autoreactive T cell responses that lead to autoimmunity. Self-reactive CD4(+) T cells are major drivers of autoimmune disease, but their activation is normally prevented through regulatory mechanisms that limit the immunostimulatory presentation of self antigens. Here we found that the apoptosis of infected host cells enabled the presentation of self antigens by major histocompatibility complex class II molecules in an inflammatory context. This was sufficient for the generation of an autoreactive TH17 subset of helper T cells, prominently associated with autoimmune disease. Once induced, the self-reactive TH17 cells promoted auto-inflammation and autoantibody generation. Our findings have implications for how infections precipitate autoimmunity.