Soil heavy metals (HMs) pollution is a growing global concern, mainly in regions with rapid industrial growth. This study assessed the concentrations, potential sources, and health risks of HMs in agricultural soils near marble processing plants in Malakand, Pakistan. A total of 21 soil samples were analyzed for essential and toxic HMs via inductively coupled plasma‒optical emission spectrometry (ICP‒OES), and probabilistic health risks were evaluated via Monte Carlo simulation. The concentrations (mg/kg) of Ca (29,250), P (805.5) and Cd (4.5) exceeded the average shale limits of 22,100, 700, and 3.0 mg/kg, respectively, and indices such as Nemerow’s synthetic contamination index (NSCI) and the geoaccumulation index (I
geo
) categorized the soil sites as moderately polluted. The potential ecological risk index (PERI) indicated considerable to high ecological risk for As and Cd. The deterministic analysis indicated non-carcinogenic risks for children (HI > 1), whereas the probabilistic analysis suggested no significant risk (HI < 1) for both adults and children. Both methods indicated that the total cancer risk for Cr, Ni, Cd, and As exceeded the USEPA safety limits of 1.0E-06 and 1.0E-04. Sensitivity analysis identified heavy metal concentration, exposure duration, and frequency as key risk factors. The study suggested that HM contamination is mainly anthropogenic, poses a threat to soil and human health, and highlights the need for management strategies and surveillance programs to mitigate these risks.