Not least because of unsubstantiated claims by Greta Thunberg, the rail transport mode was praised as a particularly environmentally friendly means of transport. However, one from the University of St. Gallen on behalf of the Friedrich Naumann Foundation has now come to the conclusion that the railway is far less environmentally friendly than what politicians or Thunberg's supporters claim.
If you measure the carbon dioxide emissions directly on an electric locomotive, ideally you will not be able to measure anything. In many countries, however, a significant proportion of traction current comes from coal-fired power, which is anything but climate-friendly. Thus, there is only a shift in the location of the emissions.
Furthermore, it is ignored that seen worldwide, like the vast majority of trains, are powered by diesel engines rather than electrically. In many places the locomotives are hopelessly outdated and do not even have particle filters, which have long been standard in motor vehicles. The result: old diesel locomotives are about as environmentally friendly as old marine diesel engines.
The study mentioned at the beginning deals primarily with the carbon dioxide emissions that arise before a train even comes on the rails. The construction of the vehicles, but especially the necessary infrastructure such as train stations and railways, causes enormous environmental pollution. If you take this into account in the overall calculation, the image of the railroad is no longer green at all. Long-distance buses with modern Euro 6 diesel engines do better here. The overall balance of aviation is also at a level that is at least not significantly worse than that of rail transport.
Viewed as a whole, however, a turnaround can only be brought about if all modes of transport, i.e. rail, road, air and water, are meaningfully linked with one another and thus individual traffic is drastically reduced. Every motor vehicle that disappears from the street and people travel on public transport that would run anyway is a win for the climate. The aforementioned study can under this link in PDF format be downloaded.