Limited information is available on potential predictive value of environmental chemicals for mortality. Our study aimed to investigate the associations between 43 of 8 classes representative environmental chemicals in serum/urine and mortality, and further develop the interpretable machine learning models associated with environmental chemicals to predict mortality. A total of 1602 participants were included from the National Health and Nutrition Examination Survey (NHANES). During 154,646 person-months of follow-up, 127 deaths occurred. We found that machine learning showed promise in predicting mortality. CoxPH was selected as the optimal model for predicting all-cause mortality with time-dependent AUROC of 0.953 (95%CI: 0.951–0.955). Coxnet was the best model for predicting cardiovascular disease (CVD) and cancer mortality with time-dependent AUROCs of 0.935 (95%CI: 0.933–0.936) and 0.850 (95%CI: 0.844–0.857). Based on clinical variables, adding environmental chemicals could enhance the predictive ability of cancer mortality (P