Intensified agricultural activities with an excessive fertiliser utilisation result in high penetration rates for several chemical compounds through soil to the ground water reservoirs. One of the main components in fertilisers are nitrate ions, which at high concentrations have harmful effects on human health. There is a number of available technologies for nitrate removal, but the majority of them use chemical additives and generate waste that has to be treated before their release to the environment. One promising alternative is the electrodialysis (ED) process. To make the process more sustainable and allow the deployment of such systems to remote areas where limits on electric power consumption may be present, the ED system can be powered by photovoltaic (PV) solar panels. The challenge is to operate the system efficiently under the intermittence of the solar radiation and the variations in the water concentration of nitrates. In this work, a mathematical model describing the removal of nitrate ions, under a variety of meteorological conditions, and for a variable daily demand of drinking water has been developed. Solar radiation and nitrate feed are real data from an area with drinking water contamination problem. This simulation model predicts the removal rate of nitrate ions, the sizing of the solar panels and the capacity of the battery with respect to the battery’s state of charge. Efficient energy management strategies are developed to ensure that the targeted pure water demand in terms of volume and concentration of nitrates is met and the use of non-renewable, externally provided electricity is minimised.