a, The top 30 genes upregulated in colonic neurons by AHR-ligand treatment (AHR-induced CUEGs) were identified on the basis of fold-change criteria (log 2 -transformed fold change = 2 < maximum). b, Cyp1a1::cre;Rosa26eYFP reporter mice were intraperitonially injected with 3MC five days before GFP immunostaining. CYP1A1 induction in response to ligand-activated AHR signalling is expected to induce expression of eYFP. c, d, Immunostaining of myenteric ganglia from the colon (c) and small intestine (d) of 3MC-treated Cyp1a1::cre;Rosa26 mice for peripherin (red), HuC/D (blue) and eGFP (green). Scale bars, 100 μm. Data represent three independent experiments. e–g, Live calcium imaging of colonic myenteric plexus preparations from Wnt1::cre;Rosa26-GCaMP6f mice. Electrically stimulated Ca2+ transients in enteric neurons under control conditions (e) or in the presence of the ML-133 blocker21 (10 μM) (f). Data represent four independent experiments. The greyscale images depict a proximal colon myenteric plexus preparation in which enteric neurons were stimulated by a single electrical pulse (top panels) or an electrical pulse train (1 s, 20 Hz; bottom panels) via a focal electrode positioned on an internodal strand leading into the myenteric ganglion in the field of view. Left, baseline before stimulation. Middle, peak GCaMP6f fluorescence of the same ganglion upon electrical stimulation. Scale bars, 20 μm. Right, Ca2+ transients of individual enteric neurons (indicated by colour-coded arrows shown in the middle panels) induced by electrical stimulation. The electrical stimulus was applied at 10 s as marked by the black arrows. Comparison of the average maximal GCaMP6f fluorescence amplitudes of neuronal Ca2+ responses (mean ± s.e.m.) under control conditions (e) or the presence of ML-133 (f) upon single pulse (top) (n = 457 neurons) and pulse train (bottom) (n = 526 neurons) electrical stimulation is shown in g (two-sided paired t-test). h, i, Myenteric ganglia from colon of control (h) and antibiotic-treated (i) mice hybridized with the Kcnj12 RNAscope probe. Dotted line defines the borders of myenteric ganglia and arrows indicate Kcnj12-expressing cells. Scale bars, 30 μm. Data represent two independent experiments. j, Quantification of RNAscope signal (mean ± s.e.m.) shown in h and i (two-sided non-parametric Mann–Whitney U-test). n = 421 neurons from 4 control and 468 neurons from 4 antibiotic-treated mice. Abx, antibiotics. k, l, Myenteric ganglia from colon of SPF mice hybridized with the Ahr (green) (k)and Kcnj12 (blue) (l) RNAscope probes and immunostained with HuC/D (data not shown). Dotted line defines the borders of myenteric ganglia and arrows indicate AHR- and KCNJ12-expressing neurons. Scale bars, 30 μm. Data represent two independent experiments. m, Scatter plot shows positive correlation in RNAscope signal for Ahr (k) and Kcnj12 (l) in myenteric neurons (F-test). n = 1,037 neurons from 3 mice. n, o, Immunostaining of myenteric ganglia from control (Ahr+/+;Rosa26eYFP injected with the AAV9-CaMKII-Cre vector) (n) and AhrEN-KO (o) mice for AHR (red) and eYFP (green). Note the lack of overlap between green and red signal in the case of AhrEN-KO (o). Data are representative of two independent experiments. Scale bars, 30 μm. p, Percentage of AHR+ neurons in myenteric ganglia of control (Ahr+/+;Rosa26eYFP mice injected with the AAV9-CaMKII-Cre vector) and AhrEN-KO mice. Random images were acquired from the colon of each biological replicate (n = 9 for control, n = 13 for AhrEN-KO), and the average percentage (mean ± s.d.) of AHR+ HuC/D + cells among the total population of HuC/D+ neurons was calculated (two-sided Student’s t-test). Source data