 The town was originally built because of the railway.In 1870, a track to Saint Petersburg, Russia, was built (see Riihimäki–Saint Petersburg Railway).The amount of traffic increased, and by the 20th century, Riihimäki became an important crossing-point station.