Diabetes, a pervasive global health concern, presents diagnostic challenges due to its nuanced onset and far-reaching implications. Traditional diagnostic approaches, reliant on time-consuming assessments, necessitate a paradigm shift towards more efficient methodologies. In response, this study introduces a diagnostic support system leveraging the power of optimized machine learning algorithms. Addressing class imbalance within a dataset comprising 768 records, our methodology intricately weaves together feature selection, dimensionality reduction techniques, and grid search optimization. Specifically, the Extra Trees model, fine-tuned via grid search, emerges as the most potent, showcasing remarkable performance metrics: an accuracy score of 92.5%, an F1-score of 93.7%, and an AUC-ROC of 92.47%. These findings underscore the pivotal role of machine learning in reshaping diabetes diagnosis, offering transformative possibilities for global healthcare enhancement.