The document presents a new clustering algorithm called Ameliorate Threshold Distributed Energy Efficient Clustering (ATDEEC) for heterogeneous wireless sensor networks, aimed at extending network lifetime by optimizing energy use. The proposed method involves excluding nodes closest to the base station from the clustering process, which enhances data transmission efficiency and increases the number of received packets. Simulation results indicate that ATDEEC outperforms existing protocols, such as TDEEC, in terms of energy efficiency and overall network stability.