The original railroad between
Keelung and
Twatutia was completed in 1891. The section between
Twatutia and
Hsinchu was finished in 1893. However, in the
Japanese era, these sections were all rebuilt by the
Government-General of Taiwan as part of its Taiwan Trunk Railway (,
Jūkan Tetsudō) project. The Taiwan Trunk Railway was completed in 1908 with route from Kīrun (,
Keelung) through Taihoku (,
Taipei), Shinchiku (,
Hsinchu), Taichū (,
Taichung), Tainan (,
Tainan), to Takao (,
Kaohsiung). The Taiwan Trunk Railway at that time went through all major cities in western
Taiwan. However, the terrain around Taichū (
Taichung) created a significant bottleneck for
rail freight transport. To resolve this issue, the
Government-General of Taiwan decided to build a Coastal Line (,
Kaigan-sen) between Chikunan (,
Zhunan) and Shōka (,
Changhua) to relieve the congestion. The construction of the Coastal Line was started in 1919 and completed in 1922. The Coastal Line then became a part of the main West Coast Line, and the original railway through Taichū (
Taichung) was named as a separate line (
Taichung line). Due to service patterns, the following lines are often collectively referred to as the
Western main line () ==Stations==