The vitamin B group, including riboflavin, plays paramount roles in one-carbon metabolism (OCM), and disorders related to this pathway have been linked to cancer development. The variants of genes encoding OCM enzymes and the insufficiency of B vitamins could contribute to carcinogenesis. Very few observational studies have revealed a relationship between riboflavin and gastric cancer (GC), especially under conditions of modified genetic factors. We carried out a study examining the association of riboflavin intake and its interaction with MTRR (rs1532268) genetic variants with GC risk among 756 controls and 377 cases. The odds ratios (ORs) and 95% confidence intervals (CIs) were evaluated using unconditional logistic regression models. We observed protective effects of riboflavin intake against GC, particularly in the female subgroup (OR=0.52, 95% CI 0.28-0.97, p-trend=0.031). In the MTRR (rs1532268) genotypes analysis, the dominant model showed that the effects of riboflavin differed between the CC and CT+TT genotypes. Compared with CC carriers, low riboflavin intake in T+ carriers was significantly associated with a 93% higher GC risk (OR=1.93, 95% CI 1.09-3.42, p-interaction=0.037). In general, higher riboflavin intake might help reduce the risk of GC in both CC and TC+TT carriers, particularly the T+ carriers, with marginal significance (OR=0.54, 95% CI 0.28-1.02, p-interaction=0.037). Our study indicates a protective effect of riboflavin intake against GC. Those who carry at least one minor allele and have low riboflavin intake could modify this association to increase GC risk in the Korean population.