The study was conducted in Cerritos, San Luis Potosí, México, near the Guaxcama mine, focused on environmental contamination (groundwater and agricultural soil) from antimony (Sb), arsenic (As), lead (Pb), cadmium (Cd), and mercury (Hg). In March 2022, 20 agricultural soil and 16 groundwater samples were collected near the historically cinnabar (HgS)- and arsenopyrite (FeAsS)-rich Guaxcama mine. Hydride generation atomic fluorescence spectrometry (HG-AFS) for As, cold vapor atomic fluorescence spectrometry (CV-AFS) for Hg, and inductively coupled plasma optical emission spectrometry (ICP-OES) for Cd, Pb, and Sb were used for the determinations of potentially toxic elements (PTEs). While concentrations of Cd, Hg, Pb, and Sb in groundwater were below detection limits, As levels exhibited a range from 40.9 ± 1.4 to 576.0 ± 1.0µg/L, exceeding permissible limits for drinking water (10µg/L). In agricultural soil, As was between 7.67 ± 0.16 and 24.1 ± 0.4µg/g, Hg ranged from 0.203 ± 0.018 to 2.33 ± 0.19µg/g, Cd from 2.53 ± 0.90 to 2.78 ± 0.01µg/g, and Pb from 11.7 ± 1.2 to 34.3 ± 4.1µg/g. Only one study area surpassed the Mexican As soil limit of 22µg/g. Sequential extraction (four-step BCR procedure) indicated significant As bioavailability in soil (fractions 1 and 2) ranging from 3.66 to 10.36%, heightening the risk of crop transfer, in contrast to the low bioavailability of Hg, showing that fractions 1, 2, and 3 were below the limit of quantification (LOQ). Crucial physicochemical parameters in soil, including nitrate levels, pH, and organic matter, were pivotal in understanding contamination dynamics. Principal component analysis highlighted the influence of elements like Fe and Ca on phytoavailable As, while Pb and Cd likely originated from a common source. Ecological risk assessments underscored the significant impact of pollution, primarily due to the concentrations of Cd and Hg. Non-cancer and cancer risks to residents through As poisoning via contaminated water ingestion also were found. The hazard index (HI) values varied between 4.0 and 82.2 for adults and children. The total incremental lifetime cancer risk (TILCAR) values for adults ranged from 7.75E - 04 to 1.06E - 02, whereas for children, the values were from 2.47E - 04 to 3.17E - 03.