Obesity is a critical health condition that severely affects an individual's quality of life and well-being. The occurrence of obesity is strongly associated with extreme health conditions, such as cardiac diseases, diabetes, hypertension, and some types of cancer. Therefore, it is vital to avoid obesity and or reverse its occurrence. Incorporating healthy food habits and an active lifestyle can help to prevent obesity. In this regard, artificial intelligence (AI) can play an important role in estimating health conditions and detecting obesity and its types. This study aims to see obesity levels in adults by implementing AIenabled machine learning on a real-life dataset. This dataset is in the form of electronic health records (EHR) containing data on several aspects of daily living, such as dietary habits, physical conditions, and lifestyle variables for various participants with different health conditions (underweight, normal, overweight, and obesity type I, II and III), expressed in terms of a variety of features or parameters, such as physical condition, food intake, lifestyle and mode of transportation. Three classifiers, i.e., eXtreme gradient boosting classifier (XGB), support vector machine (SVM), and artificial neural network (ANN), are implemented to detect the status of several conditions, including obesity types. The findings indicate that the proposed XGB-based system outperforms the existing obesity level estimation methods, achieving overall performance rates of 98.5% and 99.6% in the scenarios explored.