Liver diseases (e.g. cirrhosis, hepatitis, and fatty liver disease) are globally one of the leading causes of mortality and are typically diagnosed in advanced stages due to vague symptoms and the difficulty involved in existing diagnostic techniques (e.g. biopsies). To optimize the early diagnosis of liver disease, this study proposes an enhanced, non-invasive approach using machine learning techniques. The research is enriched with a full pipeline, from exploratory data analysis and imputation of the dataset, treatment of the outlier, encoding of labels and scaling using ILPD (Indian Liver Patient Dataset). The classification models compared were RandomForest, XGBoost, LGBM, and CatBoost. The CatBoost algorithm fine-tuned with RandomizedSearchCV showed the highest performance with a test accuracy of 93%. The performance was again better than any already published methods showing that advanced ensembling and hyperparameter optimization worked. The proposed model is suitable for incorporation into clinical decision support systems and provides reliable and accurate diagnostic assistance. In addition to its high accuracy, the model is robust for missing and categorical data, which is a challenge in any real-world clinical scenario. These findings add to the growing body of evidence supporting AI-based medical diagnostics and suggest that CatBoost is a highly promising tool for facilitating timely screening and diagnosis of liver disease. Furthermore, the study stresses the need for thorough preprocessing and cross-validation, which serve to reduce biases that are present in widely applied datasets. Ongoing future efforts may involve the integration of multi-source data and implementation of explainable AI techniques to allow for wider clinical trust and use.