Mangrove forests play an important role in fragile environments for coastal protecting, water quality and sediment filters. They provide habitat for birds, reptiles or fish. In last 25 years, this area has been severely depleted by the conversion to agricultural crops, aquaculture and pollution. The increased use of fertilizer and long periods of high salinity levels has considerably reduced the population of mangroves. Thus, this paper proposes the development of a low cost wireless salinity sensor network to control floodgates of fresh water from lakes and reservoirs which reach the mangrove area. The system consists of a set of programmable nodes able to communicate with the control gate system. These nodes send the water characteristics to the systems that open the floodgates of fresh water. The system helps us to control and get lower salinity levels and avoid the water logging. Having low cost sensors will facilitate the deployment of wireless sensor networks.