Historical mining activities are a source of environmental pollution that affects the food chain and the health of human beings. This study aimed to assess the accumulation of arsenic (As) and lead (Pb) in vegetables grown in agricultural soils polluted by historical mining in Zacatecas, Mexico. The concentration of As and Pb in agricultural soil and edible parts of carrot (Daucus carota L.), garlic (Allium sativum L.), and pepper (Capsicum annum L.) were analyzed by atomic absorption spectrometry. Also, the As and Pb pollution index and soil-vegetable bioconcentration factor were determined. The pH values of the farmland were moderately alkaline. The concentration of As in agricultural soil exceeds the permissible limit of Mexican and international standards representing public and environmental health risks. The Pb content in most soil samples was low, and only two soil samples exceeded the permissible limit of Mexican and international standards. The As and Pb content in edible parts of vegetables exceeded the national standards from various countries and values established by Codex Alimentarius (FAO-WHO). The highest As concentration was found in C. annum (111 mg kg−1) and A. sativum (100 mg kg−1). The highest concentration of Pb was in pepper fruits. The pollution index indicates that the soil sample is classified as polluted, and its quality is not suitable for agricultural use; thus, the vegetables cannot safely be consumed. Among vegetables, the higher BCF value was for As, ranging from 2.33 to 0.64, and the average for all vegetable samples was 1.01. According to the findings, the state and national agricultural and health authorities should not recommend cultivating vegetables in agricultural soil located in this region. Likewise, preventive measures must be taken to avoid consuming polluted vegetables and certifying their safety grade.