
In many developing-region contexts, microbial testing of groundwater remains costly, time-intensive, and logistically demanding. This study proposes an explainable, data-efficient machine-learning framework to predict microbial contamination risk in groundwater using low-cost physicochemical and heavy-metal parameters, aligned with the NIS 554:2015 national drinking-water standard of Nigeria. We collected 50 borehole water samples across three Delta State communities (viz., Ugbomro, Okorikpehre, and Iterigbi), measuring parameters such as pH, total dissolved solids (TDS), electrical conductivity (EC), turbidity, and metal concentrations, alongside total coliform counts. We built and compared four classifiers (logistic regression, support vector machine, random forest, and XGBoost) to predict the binary outcome of microbial presence (coliforms > 0). Explainability was assessed using logistic coefficients and SHAP (SHapley Additive exPlanations), while physicochemical exceedance flags were derived from NIS 554:2015 limits and combined with machine learning (ML) probabilities via a decision rule to produce an “overall unsafe” indicator. The best model achieved an F1 score of ~0.60 on the test set and a receiver operating characteristic area under the curve (ROC-AUC) of ~0.50 and recall of ~0.75 in cross-validation on the training set; logistic regression revealed zinc, pH, TDS, and EC as the most influential positive predictors, whereas cadmium and lead had unexpectedly negative associations. Wilcoxon testing (p = 0.125) indicated no significant difference between the random forest and logistic regression performance, underscoring the value of simpler, more interpretable models in small-sample settings. The hybrid decision rule increased sensitivity to ~0.91, supporting its utility for triage screening in resource-constrained regions. These findings demonstrate that low-cost surrogate parameters combined with explainable ML and regulatory thresholds can deliver actionable microbial-risk screening for rural groundwater systems.