That’s the suggestion from climate change charity 10:10 and Imperial College London’s Energy Futures Lab, which say this could reduce strain on the electricity grid by bypassing it altogether.

They believe connecting solar arrays and battery storage units to rail substations could supply around 10% of the energy needed to power trains on the UK’s electrified routes each year.

As well as reducing emissions, the groups expect this would be cheaper than the electricity currently supplied via the grid.

They predict around 6% of the power needed to run the London Underground could be supplied directly by solar, with panels being installed above ground on derelict land, train depot roofs and station car parks.

Lisbeth Frømling, Chief of Quality, Health, Safety and Environment at Network Rail, said: “Integrating renewable energy into the rail infrastructure would be a major step forward to reaching our goal of delivering a low carbon railway.

“As one of the largest energy consumers in the country we welcome this important research and the opportunity to collaborate with others to enable innovation.”

The project partners are now seeking funding to develop a prototype system for pilot testing.