A Wireless Sensor Network (WSN) is one of the most challenging areas of Internet of Things (IoT), the reason why this chapter is focused on them. A WSN is composed of a set of hundreds of devices deployed in a common area, with communication between each other and a common purpose. Each device is able to transmit/receive data to a set of devices or to all devices. These devices are connected according to a topology, either be fixed or not, at the beginning of the process.