In the field of precision healthcare, where accurate decision-making is paramount, this study underscores the indispensability of eXplainable Artificial Intelligence (XAI) in the context of epilepsy management within the Internet of Medical Things (IoMT). The methodology entails meticulous preprocessing, involving the application of a band-pass filter and epoch segmentation to optimize the quality of Electroencephalograph (EEG) data. The subsequent extraction of statistical features facilitates the differentiation between seizure and non-seizure patterns. The classification phase integrates Support Vector Machine (SVM), K-Nearest Neighbor (KNN), and Random Forest classifiers. Notably, SVM attains an accuracy of 97.26%, excelling in the precision, recall, specificity, and F1 score for identifying seizures and non-seizure instances. Conversely, KNN achieves an accuracy of 72.69%, accompanied by certain trade-offs. The Random Forest classifier stands out with a remarkable accuracy of 99.89%, coupled with an exceptional precision (99.73%), recall (100%), specificity (99.80%), and F1 score (99.86%), surpassing both SVM and KNN performances. XAI techniques, namely Local Interpretable Model-Agnostic Explanations (LIME) and SHapley Additive exPlanation (SHAP), enhance the system's transparency. This combination of machine learning and XAI not only improves the reliability and accuracy of the seizure detection system but also enhances trust and interpretability. Healthcare professionals can leverage the identified important features and their dependencies to gain deeper insights into the decision-making process, aiding in informed diagnosis and treatment decisions for patients with epilepsy.