Wireless Sensor Networks (WSNs) is made up of a network of many compact and constrained sensors. Constrained Application Protocol (CoAP) was designed particularly for the constrained nodes and networks in WSNs as a unique web transfer protocol by the Internet engineering task force (IETF) developed. Time synchronization of these low power sensor modules is in high demand. This paper proposes a time synchronization module for CoAP and focuses on the energy efficiency of the WSN for CoAP using NS2, which will help to reduce the overall network overhead and minimize the energy consumption. © 2019 IEEE.