Human and animal studies strongly suggest that dietary gluten could play a causal role in the etiopathogenesis of type 1 diabetes (T1D). However, the mechanisms have not been elucidated. Recent reports indicate that the intestinal microbiome has a major influence on the incidence of T1D. Since diet is known to shape the composition of the intestinal microbiome, we investigated using non-obese diabetic (NOD) mice whether changes in the intestinal microbiome could be attributed to the pro- and anti-diabetogenic effects of gluten-containing and gluten-free diets, respectively. NOD mice were raised on gluten-containing chows (GCC) or gluten-free chows (GFC). The incidence of diabetes was determined by monitoring blood glucose levels biweekly using a glucometer. Intestinal microbiome composition was analyzed by sequencing 16S rRNA amplicons derived from fecal samples. First of all, GCC-fed NOD mice had the expected high incidence of hyperglycemia whereas NOD mice fed with a GFC had significantly reduced incidence of hyperglycemia. Secondly, when the fecal microbiomes were compared, Bifidobacterium, Tannerella, and Barnesiella species were increased (p = 0.03, 0.02, and 0.02, respectively) in the microbiome of GCC mice, where as Akkermansia species was increased (p = 0.02) in the intestinal microbiomes of NOD mice fed GFC. Thirdly, both of the gluten-free chows that were evaluated, either egg white based (EW-GFC) or casein based (C-GFC), significantly reduced the incidence of hyperglycemia. Interestingly, the gut microbiome from EW-GFC mice was similar to C-GFC mice. Finally, adding back gluten to the gluten-free diet reversed its anti-diabetogenic effect, reduced Akkermansia species and increased Bifidobacterium, Tannerella, and Barnesiella suggesting that the presence of gluten is directly responsible for the pro-diabetogenic effects of diets and it determines the gut microflora. Our novel study thus suggests that dietary gluten could modulate the incidence of T1D by changing the gut microbiome.