and energy is a critical resource. Once a sensor node's battery is depleted, it can no longer function, leading to gaps in data collection and potentially compromising the entire network. In WSN, sensors may have different energy requirements. As the number of nodes increases, the volume of data transmitted can lead to network congestion and increased energy consumption. Efficient data routing and transmission strategies are essential to mitigate these issues. The lifetime of a WSN is often limited by the energy of its nodes. Therefore, strategies that prolong the operational time of the network are crucial for maintaining continuous monitoring and data collection. However, the challenge is selecting a sensor that has enough energy to be the Cluster Head (CH). Clustering in WSNs provides a structured technique for WSN organization, resource management, and communication optimization, leading to improved scalability, efficiency, reliability, and performance of wireless sensors [2; 4]. Clustering is a method used to group sensor nodes into clusters, where each cluster has a designated leader known as the cluster head (CH). This approach reduces the amount of data that needs to be transmitted to the sink node, as data from individual nodes can be aggregated at the cluster head before being sent. While clustering can enhance energy efficiency and data management, traditional methods may not effectively adapt to the dynamic nature of WSNs, especially when considering the varying energy levels and capabilities of different sensor nodes. Again, it helps WSNs to optimize energy consumption through the Cluster Head, Duty Rotation, Data Aggregation, Efficient Routing, Sleep Scheduling, and Localized Processing [2]. Nature-inspired optimization methods are one of the approaches to solving wireless sensor network problems in terms of finding the optimal approach to cluster formation. Nature-inspired approaches help avoid unpromising search paths in any optimization problem, thus helping reduce the time spent searching for the best or near-optimal solutions. Examples of such methods include Bee Colony Optimization (BCO), which is a nature-inspired optimization algorithm based on honeybees' foraging behavior [5; 6]. BCO is a metaheuristic optimization algorithm inspired by the foraging behavior of honeybees. It mimics how bees search for food and communicate the location of food sources to one another. BCO can be used to optimize routing and clustering by efficiently selecting cluster heads based on factors like energy levels and node proximity. The foraging behavior of honeybees could be applied to find the most efficient routes for data transmission in a WSN, thereby reducing energy consumption, improving network lifetime, and enhancing the overall network performance [3]. Unfortunately, the traditional Bee Colony Optimization (BCO) faces challenges such as premature convergence, where the algorithm settles on suboptimal solutions too quickly, limiting its effectiveness in complex scenarios [5]. This also limits its performance in finding the optimal routing paths in heterogeneous sensor networks. This is because there is diversity and variability among the sensor nodes within the network. This study focuses on developing an efficient clustering algorithm by combining the k-mean clustering technique with the Bee Colony Optimization algorithm (K-BCO) to address the challenge associated with the traditional BCO technique. K-means is a popular clustering algorithm that partitions data into K clusters based on similarity [7]. It is straightforward and efficient but can struggle with dynamic environments and may not account for the varying energy levels of sensor nodes in WSNs. In a heterogeneous WSN, sensors may have varying hardware specifications, memory capacity, processing power, and energy resources [8]. For instance, some sensor nodes might have strong batteries or an efficient sensing capability, while others may be more limited.