Autism Spectrum Disorder (ASD) is a neurodevelopmental condition affecting learning, communication, and behavior, with rising prevalence in Nigeria and globally. Accurate diagnosis often relies on screening tools and clinical observation. This study compares the performance of five machine learning techniques for ASD detection: Naïve Bayes, Support Vector Machine (SVM), Logistic Regression, K-Nearest Neighbor (KNN), and Random Forest. Using a publicly available dataset of 704 instances with 21 attributes, models were evaluated across two phases: first, using all features, and then using Chi-Square-selected features. Results showed that Random Forest and Logistic Regression achieved perfect scores (Area Under the Curve [AUC] = 1.0, Accuracy = 1.0) with all features, suggesting potential over-fitting. Models like SVM, Naïve Bayes, and KNN also performed strongly (AUC > 0.99). After feature selection, AUC scores slightly decreased (0.98–0.99), but accuracy remained above 0.93, indicating improved generalization. While Random Forest and Logistic Regression excelled, SVM and Naïve Bayes provided robust performance with better potential for generalization. This study emphasizes the significance of feature selection in striking a balance between accuracy and generalization for ASD diagnosis. Future research should investigate the application of these methods to ASD datasets from Nigeria, aiming to enhance model robustness and real-world applicability.