Food safety emphasizes risk control in the production process, and has attracted much attention from food regulators and consumers in recent years. The objectives of this study were to conduct early key risk factors identification and risk modeling for vegetable safety production. To achieve these objectives, this article quantitatively identified the key direct and indirect risk factors in vegetable safety production through questionnaire surveys and a multivariate linear model, and modeled the effects of key risk factors affecting vegetable safety production based on the catastrophe progression method. Based on 973 valid farmers' questionnaires from Beijing, China, the results showed that key direct risk factors are production violation, farmland biological control, pesticide and fertilizer use criteria, and agricultural consumable handling; key indirect risk factors included cooperative participation, planting years, prohibited pesticide knowledge, production recording, and product type. Through the empirical analysis, it can be seen that there are regional differences in the production risk of vegetable farmers in Beijing. The production risks of Changping, Huairou, and Shunyi are the most serious; from a city-wide perspective, the risk of farmland biological control is greatest, followed by risk aversion ability. The findings of this research have important implications for safe vegetable production and farmers' production risk control.