The wireless sensor networks have long been an attractive field to the researchers and scientists for its ease in deployment and maintenance. In this research, we focus on the maximization of network lifetime which has become a critical issue in sensor networks. Clustered organization of nodes with aggregation of data at the cluster head becomes one of the significant means to extend life expectancy of the network. This paper proposes Particle Swarm Optimization (PSO) approach for generating energy-aware clusters by optimal selection of cluster heads. The PSO eventually reduces the cost of locating optimal position for the head nodes in a cluster. In addition, we have implemented the PSO-based approach within the cluster rather than base station, which makes it a semi-distributed method. The selection criteria of the objective function are based on the residual energy, intra-cluster distance, node degree and head count of the probable cluster heads. Furthermore, influence of the expected number of packet retransmissions along the estimated path towards the cluster head is also reflected in our proposed energy consumption model. The performance evaluation of our proposed technique is carried out with respect to the well-known cluster-based sensor network protocols, LEACH-C and PSO-C respectively. Finally, the simulation clarifies the effectiveness of our proposed work over its comparatives in terms of network lifetime, average packet transmissions, cluster head selection rounds supported by PSO and average energy consumption.