This paper proposes an artificial neural network (ANN) to predict the solar energy generation produced by photovoltaic generators. The intermittent nature of solar power creates two main issues. Firstly, power production and demand have to be balanced to ensure the control of the whole system, and the inherent variability of clean energies makes this difficult. Secondly, energy generation companies need a highly accurate day-ahead or intra-day estimation of the energy to be sold in the electricity pool. For the tool developed in this paper, we address the issue of the complexity of control in systems that are based on solar energies. The tool's ability to predict the parameters that are involved in solar energy production will allow us to estimate the future power production in order to optimise grid control. Our tool uses an ANN which we developed using MATLAB (R) software. The results were validated by analysing the root mean square error of the prediction for days outside the database used for training the ANN. The difference between the actually produced and predicted energy is about 0.5-9%, meaning that the accuracy of our tool is sufficient enough to be installed in systems which have integrated solar generators.