ABSTRACT Early identification of neonatal jaundice (NJ) appears to be essential to avoid bilirubin encephalopathy and neurological sequelae. The interaction between gut microbiota and metabolites plays an important role in early life. It is unclear whether the composition of the gut microbiota and metabolites can be used as an early indicator of NJ or to aid clinical decision-making. This study involved a total of 196 neonates and conducted two rounds of “discovery-validation” research on the gut microbiome-metabolome. It utilized methods of machine learning, causal inference, and clinical prediction model evaluation to assess the significance of gut microbiota and metabolites in classifying neonatal jaundice (NJ), as well as the potential causal relationships between corresponding clinical variables and NJ. In the discovery stage, NJ-associated gut microbiota, network modules, and metabolite composition were identified by gut microbiome-metabolome association analysis. The NJ-associated gut microbiota was closely related to bile acid metabolites. By Lasso machine learning assessment, we found that the gut bacteria were associated with abnormal bile acid metabolism. The machine learning-causal inference approach revealed that gut bacteria affected serum total bilirubin and NJ by influencing bile acid metabolism. NJ-associated gut bile acids are potential biomarkers of NJ, and clinical prediction models constructed based on these biomarkers have some clinical effects and the model may be used for disease risk prediction. In the validation stage, it was found that intestinal metabolites can predict NJ, and the machine learning-causal inference approach revealed that bile acid metabolites affected NJ itself by affecting the total bilirubin content. Intestinal bile acid metabolites are potential biomarkers of NJ. By applying machine learning-causal inference methods to gut microbiome-metabolome association studies, we found NJ-associated intestinal bacteria and their network modules and bile acid metabolite composition. The important role of intestinal bacteria and bile acid metabolites in NJ was determined, which can predict the risk of NJ.