A boiler is a device used to heat water or other fluids until it boils or before boiling point. The heated or vaporized fluid is then used for various process applications, such as central heating, power generation, cooking, and sanitation.
Where steam is required for space heating, the boiler is often called a steam generator. A niche application was for heating railroad passenger cars while steam locomotives were being phased out. The steam generator would be oil-fired on diesel locomotives or electrically heated on electric locomotives. Steam heating is now uncommon on trains. Modern trains are usually heated by electric heaters.