Our results show that when infected mice are treated with a TRPV1 antagonist at the initial time of infection, they fail to develop chronic pelvic pain or behavioral changes associated with anxiety and depression. Here, TRPV1 is linked to depressive disorder.