Power is supplied to moving trains with a (nearly) continuous conductor running along the track that usually takes one of two forms: overhead line, suspended from poles or towers along the track or from structure or tunnel ceilings; third rail mounted at track level and contacted by a sliding "pickup shoe". Both overhead wire and third-rail systems usually use the running rails as the return conductor but some systems use a separate fourth rail for this purpose.
In comparison to the principal alternative, the diesel engine, electric railways offer substantially better energy efficiency, lower emissions and lower operating costs. Electric locomotives are also usually quieter, more powerful, and more responsive and reliable than diesels. They have no local emissions, an important advantage in tunnels and urban areas. Some electric traction systems provide regenerative braking that turns the train's kinetic energy back into electricity and returns it to the supply system to be used by other trains or the general utility grid. While diesel locomotives burn petroleum, electricity can be generated from diverse sources including renewable energy. 
Disadvantages of electric traction include high capital costs that may be uneconomic on lightly trafficked routes; a relative lack of flexibility - since electric trains need electrified tracks (or overhead wires)- and a vulnerability to power interruptions. 
Different regions may use different supply voltages and frequencies, complicating through service and requiring greater complexity of locomotive power. The limited clearances available under overhead lines may preclude efficient double-stack container service.
Railway electrification has constantly increased in the past decades, and as of 2012, electrified tracks account for nearly one third of total tracks globally.
Selection of an electrification system is based on economics of energy supply, maintenance, and capital cost compared to the revenue obtained for freight and passenger traffic. Different systems are used for urban and intercity areas; some electric locomotives can switch to different supply voltages to allow flexibility in operation.
Six of the most commonly used voltages have been selected for European and international standardisation. Some of these are independent of the contact system used, so that, for example, 750 V DC may be used with either third rail or overhead lines.
There are many other voltage systems used for railway electrification systems around the world, and the list of railway electrification systems covers both standard voltage and non-standard voltage systems.
The permissible range of voltages allowed for the standardised voltages is as stated in standards BS EN 50163 and IEC 60850. These take into account the number of trains drawing current and their distance from the substation.