1-Deoxynojirimycin (DNJ) exerts hypoglycemic effects. However, the traditional method for DNJ extraction is inefficient, and the hypoglycemic mechanism of DNJ remains unclear. In this study, the mixed fermentation by <i>Lactobacillus fermentum</i> and <i>Saccharomyces cerevisiae</i> was used to enhance DNJ extraction efficiency. It was found that this strategy was more efficient than the traditional method as the yield improved from the original 3.24 mg/g to 5.97 mg/g. The purified DNJ significantly decreased serum glucose (<i>P</i> < 0.01) and insulin levels (<i>P</i> < 0.05), improved serum lipid levels (<i>P</i> < 0.05), and reversed insulin resistance (<i>P</i> < 0.05) in diabetic mice. These changes were caused by up-regulating the protein expression of insulin receptor and glycolysis enzymes (GK, PK, and PFK) (<i>P</i> < 0.05) and down-regulating the protein expression of insulin receptor substrate-1 and gluconeogenesis enzymes (PCB, PEPCK, FBPase, and G-6-Pase) (<i>P</i> < 0.05), thus alleviating glucose tolerance. Additionally, DNJ treatment relieved gut dysbiosis in diabetic mice by promoting the growth of <i>Lactobacillus</i>, <i>Lachnospiraceae NK4A136 group</i>, <i>Oscillibacter</i>, <i>norank Lachnospiraceae</i>, <i>Alistipes</i>, and <i>Bifidobacterium</i> (<i>P</i> < 0.05) and suppressing the growth of <i>Ruminococcaceae UCG-014</i>, <i>Weissella</i>, <i>Ruminococcus</i>, <i>Prevotellaceae Ga6A1 group</i>, <i>Anaerostipes</i>, <i>Klebsiella</i>, <i>Prevotellaceae UCG-001</i>, and <i>Bacteroidales S24-7 group</i> (<i>P</i> < 0.05).