A proper immune response ensures survival in a hostile environment and promotes longevity. Recent evidence indicates that innate immunity, beyond antimicrobial effectors, also relies on host-defensive mechanisms. The Caenorhabditis elegans transcription factor SKN-1 regulates xenobiotic and oxidative stress responses and contributes to longevity, however, its role in immune defense is unknown. Here we show that SKN-1 is required for C. elegans pathogen resistance against both Gram-negative Pseudomonas aeruginosa and Gram-positive Enterococcus faecalis bacteria. Exposure to P. aeruginosa leads to SKN-1 accumulation in intestinal nuclei and transcriptional activation of two SKN-1 target genes, gcs-1 and gst-4. Both the Toll/IL-1 Receptor domain protein TIR-1 and the p38 MAPK PMK-1 are required for SKN-1 activation by PA14 exposure. We demonstrate an early onset of immunosenescence with a concomitant age-dependent decline in SKN-1-dependent target gene activation, and a requirement of SKN-1 to enhance pathogen resistance in response to longevity-promoting interventions, such as reduced insulin/IGF-like signaling and preconditioning H(2)O(2) treatment. Finally, we find that wdr-23(RNAi)-mediated constitutive SKN-1 activation results in excessive transcription of target genes, confers oxidative stress tolerance, but impairs pathogen resistance. Our findings identify SKN-1 as a novel regulator of innate immunity, suggests its involvement in immunosenescence and provide an important crosstalk between pathogenic stress signaling and the xenobiotic/oxidative stress response.