The gene encoding for Epstein-Barr virus-induced G-protein coupled receptor 2 (EBI2) is a risk gene for inflammatory bowel disease (IBD). Together with its oxysterol ligand 7α,25-dihydroxycholesterol, EBI2 mediates migration and differentiation of immune cells. However, the role of EBI2 in the colonic immune system remains insufficiently studied. We found increased mRNA expression levels of EBI2 and oxysterol synthesizing enzymes (CH25H, CYP7B1) in the inflamed colon of patients with ulcerative colitis and mice with acute or chronic dextran sulfate sodium (DSS) colitis. Accordingly, we measured elevated extraintestinal levels of 25-hydroxylated oxysterols, including 7α,25-dihydroxycholesterol in mice with acute colonic inflammation. Knockout of EBI2 or CH25H did not affect severity of DSS colitis; however, inflammation was decreased in male EBI2-/- mice in the IL-10 colitis model. The colonic immune system comprises mucosal lymphoid structures, which number increases upon chronic inflammation in IL-10-deficient mice and in chronic DSS colitis. However, EBI2-/- mice formed significantly less colonic lymphoid structures at baseline and showed defects in inflammation-induced accumulation of lymphoid structures. In summary, we report induction of the EBI2-7α,25-dihydroxycholesterol axis in colitis and a role of EBI2 for the accumulation of lymphoid tissue during homeostasis and inflammation. These data implicate the EBI2-7α,25-dihydroxycholesterol axis in IBD pathogenesis.