Your body’s stress response can trigger several physiological changes, which can affect immune function. Why you’re stressed and how long you’re stressed can impact how your immune system responds.