T lymphocytes play a pivotal role in endogenous regulation of inflammatory visceral pain. The analgesic activity of T lymphocytes is dependent on their production of opioids, a property acquired on antigen activation. Accordingly, we investigated whether an active recruitment of T lymphocytes within inflamed colon mucosa via a local vaccinal strategy may counteract inflammation-induced visceral pain in mice. Mice were immunized against ovalbumin (OVA). One month after immunization, colitis was induced by adding 3% (wt/vol) dextran sulfate sodium into drinking water containing either cognate antigen OVA or control antigen bovine serum albumin for 5 days. Noncolitis OVA-primed mice were used as controls. Visceral sensitivity was then determined by colorectal distension. Oral administration of OVA but not bovine serum albumin significantly reduced dextran sulfate sodium–induced abdominal pain without increasing colitis severity in OVA-primed mice. Analgesia was dependent on local release of enkephalins by effector anti-OVA T lymphocytes infiltrating the inflamed mucosa. The experiments were reproduced with the bacillus Calmette–Guerin vaccine as antigen. Similarly, inflammatory visceral pain was dramatically alleviated in mice vaccinated against bacillus Calmette–Guerin and then locally administered with live Mycobacterium bovis. Together, these results show that the induction of a secondary adaptive immune response against vaccine antigens in inflamed mucosa may constitute a safe noninvasive strategy to relieve from visceral inflammatory pain.