Numerous applications rely on data obtained from a wireless sensor network where application performance is of utmost importance. However, energy usage is also important, and oftentimes, a subset of sensors can be selected to maximize application performance. We cast the problem of sensor selection as a local search optimization problem and solve it using a variant of stochastic hill climbing extended with novel heuristics. This paper introduces sensor network configuration learning, a feedback-based heuristic algorithm that dynamically reconfigures the sensor network to maximize the performance of the target application. The proposed algorithm is described in detail, along with experiments conducted and a scalability study. A quick method for launching the algorithm from a better starting point than random is also detailed. The performance of the algorithm is compared to that of two other well-known algorithms and randomness. Our simulation results obtained from running sensor network configuration learning on a number of scenarios show the effectiveness and scalability of our approach.