The Internet of Things (IoT) has significantly influenced areas such as healthcare, agriculture, industrial systems, and smart infrastructure. However, the rapid increase in the number of connected devices has introduced major security concerns, especially the risk of Distributed Denial of Service attacks. These attacks take advantage of the limited processing power and weak security configurations of many IoT devices, leading to network disruptions and service failures. This study presents an efficient intrusion detection approach that combines Binary Bat Algorithm (BBAT) based feature selection with an ensemble of lightweight machine learning models, including Extra Trees, Decision Trees, Random Forest, and XGBoost. The BBAT algorithm helps reduce the number of features while preserving classification accuracy, thereby lowering computational cost. To handle class imbalance, we incorporate the Synthetic Minority Over-sampling Technique, improving detection of underrepresented attack types. For interpretability, we apply Local Interpretable Model-agnostic Explanations (LIME) to identify key features that influence classification outcomes, supporting transparency and operational trust. The method is evaluated using three benchmark datasets-ToN-IoT, NSL-KDD, and UNSW-NB15 achieved high accuracy of 99.99%, 99.37%, and 99.08%, respectively. Comparative analysis with existing methods confirms the robustness, efficiency, and explainability of the proposed detection approach.