Fuel theft of oil pipelines is a concern faced by various countries and oil and gas companies due to its impact on the environment and the safety of neighboring communities. Oil pipeline monitoring and inspection with the support of alerts is essential to preventing suspected fuel-theft events and mitigating risks. Monitoring systems trigger alerts, and patrols are sent to confirm the occurrence of illegal tapping. However, various signals can be activated briefly, and the correct prioritization is essential to identifying illegal tapping as quickly as possible. This work aims to use machine-learning techniques to develop a predictive model capable of forecasting the probability of an event resulting in illegal tapping and understanding the factors that influence the occurrence. A Brazilian oil and gas transportation company provided data from a monitoring system supervised from January 2019 to August 2021. Five machine-learning algorithms were used in this study: Logistic Regression, Random Forest, XGBoost, Catboost, and Multilayer Perceptron. The Random Forest obtained the best results in classifying alerts associated (or not) with an illegal tapping, showing accuracy, specificity, and sensitivities of 76.8%, 68.3%, and 100%, respectively. In this problem, specificity implies reducing the sending of patrols to the field in 68.3% of circumstances, and sensitivity means that the model is a good predictor for positive cases. As for the external validation, the model also performed well, with an accuracy and specificity of 61%. The factors that most highly influenced illegal tapping occurrences were the alert duration, previous events in the same area, and events during the night.