On a visit to Newport today, Prime Minister David Cameron will unveil a £230m funding package which will see the UK Government contribute £125m to the Valley Lines electrification scheme, while also covering the full costs of electrifying the Great Western mainline to Swansea.

The Welsh Government – which will take over sponsorship and delivery of the Valley Lines project – will be liable for the remaining cost, estimated at around an extra £170m. It said this could be financed “at no net cost”.

The Prime Minister said the impact of the decision would be “huge”, while First Minister Carwyn Jones said it would help deliver the “the efficient and reliable rail service Wales needs and deserves”.

Who's funding the Valleys Lines electrification scheme?

Welsh Government

£170m

UK Government

£125m

Meanwhile, control over the Wales and the Borders rail franchise will be devolved, so that the Welsh Government chooses an operator after Arriva Trains Wales’ contract runs out in 2018.

Work could start on Valley Lines electrification as early as 2019. The move would reduce journey times from both Merthyr Tydfil and Treherbert to Cardiff to less than 50 minutes.

Mr Cameron said: “I am delighted to announce today that we are going to press ahead with the electrification of the Valley Lines.

“After years of neglect, this part of Wales will finally get the infrastructure it needs with faster, more modern, more efficient trains and the impact will be huge.

“Spreading the employment opportunities from Cardiff and out to the Valleys and helping hardworking people from all parts of this great nation to get on.

“This has only been possible because of the UK Government and shows our long-term economic plan in action and working for the people of Wales.”

Journey time from Treherbert to Cardiff

Mr Jones said: “I am delighted we have been to able to come to an agreement on the funding for this very important project.

“This deal will deliver electrification all the way from London to Swansea and enable us to move forward plans to modernise the Valleys Lines at no net cost to the Welsh Government.

“Together with an agreement to fully devolve power over the Welsh rail franchise this will allow the Welsh Government to move forward with its ambitious plans to create the efficient and reliable rail service Wales needs and deserves.”

As part of the £230m investment, the Department for Transport has agreed to finance the stretch of the Valley Lines network that runs from Cardiff to Bridgend – which also doubles as the Great Western mainline – to the tune of £105m. This will ensure the line will be electrified from London Paddington to Swansea, with a completion date of 2018.

The remaining £125m will go to electrifying the rest of the Valley Lines network.

The Valleys Lines network

The next holder of the Wales and Borders franchise will repay the capital costs of electrification of the Valley Lines through an agreed annual “access charge”.

However, because electrified trains will be more efficient and carry more passengers than the current diesel services, the next operator will require a much lower subsidy from the Welsh Government to ensure there will be no net cost.

The subsidy to the current franchise holder, Arriva Trains Wales, is around £180m a year.

The deal comes after more constructive dialogue between the two governments, facilitated by Welsh Secretary Stephen Crabb.

On taking up his role in the summer he described a deal on Valley Lines electrification as his number one priority.

Welcoming today’s announcement, he said: “This is fantastic news for Wales and provides a major incentive for businesses to invest in the country.

“I am delighted that we can now seize this opportunity to transform the Valley communities.

“Effective transport links are a vital part of any modern economy and there are few areas in the UK more in need of the improved commuter costs, travel times and more frequent train services that this investment brings.

“This is all part of our long term economic plan for Wales to rebalance the economy and stimulate job creation so that more people can benefit from the security of a regular wage.”

Transport Minister Edwina Hart said: “Today’s announcement is the result of a great deal of hard work and co-operation between the Welsh Government and The Department of Transport.

“Electrification of the mainline will be a massive step forward in creating a modern train service that is capable of meeting future demand and supporting economic growth. Upgrading, electrifying and improving the Valleys Lines is vital to our ambitions for delivering the South Wales Metro.

“I also welcome the decision to hand over control of the Welsh rail franchise to the Welsh Government, for which I have long argued is necessary to ensure we can create a train service that is suitable for Wales.”

Shadow Welsh Secretary Owen Smith said: “David Cameron has been doing the hokey cokey on funding the Welsh railways for over a year.

“First he claimed that he’d pay for the lot, including the full line to Swansea and commuter services to the Valleys, then he reneged on the deal and claimed Welsh Labour would have to pay instead and now he appears ready to split the tab.

“Welsh rail passengers will be pleased he’s finally made his mind up, even if in the end, the Welsh Government is going to have to foot some of the bill”.

Welsh Conservative leader Andrew RT Davies said: "This deal will transform the economic landscape in the Valleys and further demonstrates our determined work to help hardworking people across this region.

"We pay tribute to the commitment of the Secretary of State for Wales in getting this done and ensuring infrastructure in Wales gets the investment it needs.

"Electrification is the biggest development to hit Welsh railways since Victorian times - and I am delighted to see Conservatives delivering it."

The Welsh Government could pay the remaining capital costs of electrifying the Valley and Glamorgan Lines upfront – potentially backed with EU finance.