The Maeklong Railway (also known as the Mae Klong Railway) is a 1,000 mm (3 ft 3+ 3 ⁄8 in ) metre gauge railway that runs for nearly 65 kilometres (40 mi) between Wongwian Yai, Bangkok, and Samut Songkhram in central Thailand.
The railway became famous for its route through the Maeklong Railway Market, nicknamed (Thai: ตลาดร่มหุบ ; RTGS: Talat Rom Hup ), meaning the "umbrella pulldown market". It is one of the largest fresh seafood markets in Thailand, and is centred on the Maeklong Railway's track. Whenever a train approaches, the awnings and shop fronts are moved back from the rails, to be replaced once the train has passed.
The line consists of two sections: the eastern Mahachai Line, which runs between Samut Sakhon and Wongwian Yai with 20 stations, and the Ban Laem Line, which runs between Samut Sakhon and Samut Songkhram with 15 stations. The two stretches are separated by the Tha Chin River at Samut Sakhon. The only connection between the stations on the opposite sides of the river is by boat.
The Mae Klong Railway was built in two separate stages. The Tachin Railway Ltd, founded in 1901 with a concession from the crown of Thailand to construct a line to Samut Sakhon from Bangkok, built the 33 kilometer Mahachai Line; it opened in 1904 with eight stations. A year later, The Maeklong Railway Company opened the 34 kilometer Ban Laem Line, using three steam locomotives. The lines merged in 1907 to form the Maeklong Railway Ltd. It was originally opened as a goods line, transporting produce from the fishing ports of Samut Sakhon and Samut Songkram to the Bangkok markets. The Government of Thailand purchased the now-merged company in 1926 and electrified the eastern section, turning it into an interurban tramway. The Thai military later gained control of the railway in 1942, during World War II, and the line was brought under the control of the State Railway of Thailand in 1952 and fully merged into it by 1955. During this period of merger, the electrification was removed from the eastern section, with steam-hauled and later diesel-hauled trains replacing the old tramcars in 1959. In 1961 the line's original terminus at Pak Khlong San was closed and replaced with a bus stop, to ease traffic congestion in Bangkok, with Wongwian Yai becoming the new terminus.