The Russian settlement, likely preceded by the Manchu village of Fuyori, was founded as Nikolayevsky Post by Gennady Nevelskoy on August 13, 1850. She was named as Telin during Jurchen and Ming periods. The town owes its name to Nicholas I of Russia. It was granted municipal rights and renamed Nikolayevsk-on-Amur in 1856, when Primorskaya Oblast was established. Admiral Vasily Zavoyko supervised the construction of a naval base in Nikolayevsk.
The town emerged as an important commercial harbour and remained the administrative centre of this region until 1880, when the governor relocated to Khabarovsk. Anton Chekhov, visiting the town on his journey to the Sakhalin in 1890, noted its rapid depopulation. Nikolayevsk rebounded from the recession in 1896 with the discovery of gold and establishment of salmon fisheries.
During the Russian Civil War, the town's population plummeted from 15,000 to 2,000, as a local partisan leader, later executed by the same Bolsheviks he was supposed to be aligned to, razed the entire city to the ground and massacred the minority Japanese population.