Gully erosion is a serious environmental threat, compromising soil health, damaging agricultural lands, and destroying vital infrastructure. Pinpointing regions prone to gully erosion demands careful selection of an appropriate machine learning algorithm. This choice is crucial, as the complex interplay of various environmental factors contributing to gully formation requires a nuanced analytical approach. To develop the most accurate Gully Erosion Susceptibility Map (GESM) for India’s Raiboni River basin, researchers harnessed the power of two cutting-edge machine learning algorithm: Extreme Gradient Boosting (XGBoost) and Random Forest (RF). For a comprehensive analysis, this study integrated 24 potential control factors. We meticulously investigated a dataset of 200 samples, ensuring an even balance between non-gullied and gullied locations. To assess multicollinearity among the 24 variables, we employed two techniques: the Information Gain Ratio (IGR) test and Variance Inflation Factors (VIF). Elevation, land use, river proximity, and rainfall most influenced the basin’s GESM. Rigorous tests validated XGBoost and RF model performance. XGBoost surpassed RF (ROC 86% vs. 83.1%). Quantile classification yielded a GESM with five levels: very high to very low. Our findings reveal that roughly 12% of the basin area is severely affected by gully erosion. These findings underscore the critical need for targeted interventions in these highly susceptible areas. Furthermore, our analysis of gully characteristics unveiled a predominance of V-shaped gullies, likely in an active developmental stage, supported by an average Shape Index (SI) value of 0.26 and a mean Erosivness Index (EI) of 0.33. This research demonstrates the potential of machine learning to pinpoint areas susceptible to gully erosion. By providing these valuable insights, policymakers can make informed decisions regarding sustainable land management practices.