The oldest railway in present day Ukraine runs from the Polish border near Przemyśl to Lviv. It opened in 1861, the last section of a line from Kraków to Lemberg (Lviv), when both cities were in Galicia, a province of Austro-Hungarian Empire. The territory formed part of Poland from 1922 until the Second World War, after which it was partitioned between Poland and the Ukrainian SSR of the former Soviet Union, with the SSR becoming the independent republic of Ukraine in 1991.
The original line was built to the standard gauge of 1435mm, as were other lines in the same region, whereas lines in those parts of Ukraine that were formerly part of the Russian Empire were for the most part built to the Russian standard gauge of 1520mm gauge; the principal exception being a few narrow gauge forestry and industrial lines of 750mm gauge.
After the Second World War, the Soviet administration converted almost all the remaining 1435mm gauge lines in the Ukraine to 1520mm. This is therefore the predominant gauge today, although one 1435mm gauge line connects Kovel to the Polish border.
There are international connections with all neighbouring countries.
In 2014, following Russian military occupation and a referendum of disputed legality, Crimea declared its independence from Ukraine and resolved to become part of the Russian Federation. The Union was ratified by Russia but has not been recognized by Ukraine nor by the greater part of the international community. However, the region is now effectively under Russian control.
Also in 2014, pro-Russian separatists staged an uprising in the regions of Donetsk and Luhansk, bringing parts of both regions under separatist control. Some of the affected areas have since been returned to Ukrainian control, but some cities remain in the hands of separatists. These cities are marked thus † in the following list; the status of public transport in these cities is unclear.
Flag image from CIA World Factbook