An optimised design for an on-grid photovoltaic power supply system to be used in an electric vehicle battery swapping station is presented. How integrating photovoltaic generator systems with battery-swapping stations can enhance their sustainability, reliability, and cost-effectiveness is explored. The aim is to minimize the life cycle cost of the grid-connected photovoltaic power supply system and the cost of electricity purchased from the utility grid while maximizing its reliability constraints. Using mixed integer linear programming, the most optimal values for the decision variables were identified. The optimization results showed a total life cycle cost of R 362,934.25, an optimal energy consumption from the utility grid of 782.7 kWh, and an optimal number of 244 solar panels. This results in a daily energy saving of up to 60.01% compared to the baseline, and an economic benefit of R 1,034,273.25 over the project lifetime. Varying the weighing factor affects the multi-objective optimization sizing, and the optimal weighting factor is between 0.327 and 0.713 for the best cost-effectiveness.