To examine the mutual association of risk factors for both Helicobacter pylori (H. pylori) infection and chronic atrophic gastritis (CAG), a cross-sectional study on 954 residents of a rural town in Japan was conducted. Using an unconditional logistic model, we calculated the odds ratios (ORs) for H. pylori infection according to each lifestyle, as well as the ORs for CAG according to each lifestyle and H. pylori infection. A significant positive association was observed between H. pylori infection and the risk of CAG (OR = 6.29). On the other hand, a significant negative association was observed between high consumption of light-colored vegetables and the risk of CAG (OR = 0.68). We also used a path analysis to examine the direct relations of gender, age, and lifestyle variables to CAG, as well as the indirect relations of these variables to CAG through H. pylori infection. Aging had a significantly direct positive association with CAG. Although aging also had an indirect positive association with CAG through H. pylori infection, aging had no association with the consumption of light-colored vegetables. The high consumption of light-colored vegetables showed no association with H. pylori infection but had a significantly direct negative association with CAG. The results of this study suggest a possibility that high light-colored vegetables consumption contributes to the prevention of CAG.