Gordon Brown announced a £1.1 billion rail electrification programme today and then travelled on one of the routes to benefit from the scheme.
The Prime Minister arrived at Paddington station in London to journey on the Great Western line to Cardiff for a Cabinet meeting.
The Great Western route from London to Swansea is to be electrified over the next eight years at a cost of £1 billion.
The Government is also spending £100 million on electrifying lines between Liverpool and Manchester, with the work taking four years.
At Paddington today, Mr Brown said: "This is the future. It is green, it is faster and it's more reliable. This is about making the railways fit for the 21st century."
Asked if the Government could afford such a scheme now, Mr Brown replied: "We have set aside money for this. It's an important priority for us."
Only about one third of the rail network is electrified at the moment, with the Great Western route the last of the major routes to be still predominantly using diesel trains.
The Great Western electrification will include the lines to Oxford and to Newbury in Berkshire and will also make possible the direct replacement of the ageing InterCity 125 fleet by electric Super Express trains.
Electrification will shorten the London to Swansea journey time - currently just over three hours - by about 20 minutes.
Travelling with Mr Brown today was Transport Secretary Lord Adonis, who said: "We are electrifying 300 miles of track and we are also looking to extend electrification to other lines.
"There will be some disruptions while the work is going on but Network Rail plan to keep disruption to a minimum, with much of the work being done overnight."
Lord Adonis went on: "Electrification will mean faster, quieter and more efficient trains, which break down far less often."
Mark Hopwood, managing director of First Great Western, said: "We are really delighted with this news. It's going to transform our route and provide cleaner and more environmentally friendly travel."
The electrification announcement follows Network Rail's consultation document on electrification earlier this year, which also made the case for electrifying the Midland Main Line route.
Lord Adonis said today that the Government did consider Midland Main Line and would continue to consider it.
Anthony Smith, chief executive of rail customer watchdog Passenger Focus, said: "Passengers will welcome today's news.
"Extending electrification will improve services in the long term, reducing the pressure on the industry's costs and potentially lowering fares. Electrification will also improve reliability and potentially speed up services, which could reduce journey times.
"Passengers tell us that more trains, punctual services and getting a seat should be the industry's top priority and electrification will help address these.
"We welcome the speed of this decision and look forward to participating in the next stage of electrification to be considered."
Michael Roberts, chief executive of the Association of Train Operating Companies, said: "The announcement is excellent news and a clear demonstration of strong Government commitment to modern rail transport.
"The electrification schemes will bring real benefits to passengers and the environment."
Network Rail chief executive Iain Coucher said: "Today is a good start, but there is much further to go. We have been pushing for electrification for a long time.
"We will deliver the schemes announced today. Passengers will soon reap the benefits that electrified lines bring - quieter and smoother rides on trains that cause less wear and tear to the track, trains that are more reliable and often faster.
"Also, further electrification will also help open up more diversionary routes so that we can keep people on trains and off buses as we carry out planned rail improvement work."
Campaign for Better Transport executive director Stephen Joseph said: "We warmly welcome this announcement. It will bring us closer to European standards in rail travel, with better and more reliable trains with lower emissions.
"However, this must not be used as an excuse to increase fares that already the highest in Europe, as is happening with the new Kent high-speed services.
"Electrification brings wider benefits in cutting pollution and attracting people out of cars. These need to be paid for by the Government rather than by rail passengers."Reuse content