This document presents a fault node recovery algorithm for wireless sensor networks. It proposes combining the Grade Diffusion algorithm with a genetic algorithm to identify and replace faulty sensor nodes. The goal is to replace fewer sensor nodes while reusing existing routing paths, which increases the lifetime of the wireless sensor network and reduces replacement costs. It describes modules for sensor deployment, hole identification when sensors fail, hole healing by moving neighboring sensors, and healing holes when obstacles are present. The algorithm is implemented and evaluated using the Network Simulator NS2 tool. The results show the proposed algorithm increases the number of active sensor nodes and reduces the rate of energy consumption compared to other approaches.