Ustka (pronounced ; Ùskô; Stolpmünde) is a spa town in the Middle Pomerania region of northern Poland with 17,100 inhabitants (2001). It is part of Słupsk County in Pomeranian Voivodeship. It is located on the Slovincian Coast on the Baltic Sea. It is a port town and popular summer seaside resort of Poland. The first settlers arrived at present-day Ustka as early as the 9th century, and established a fishing settlement with the original name of Ujść. In the 10th century, it became part of the emerging country of Poland under its first ruler Mieszko I. The first historic records mention the village of Ujść or Ujście in 1310. The area at the mouth of the river Słupia was ceded to the nearby city of Słupsk in 1337 with the purpose of building a fishing harbour and a commercial port there to the Baltic Sea. According to documents in 1355 a church was built. In 1382 the city of Słupsk (Stolp) became a member of the Hanseatic League. The settlement was located in the Duchy of Słupsk, a vassal duchy of the Kingdom of Poland, and later it passed to the Duchy of Pomerania. The town was given to Brandenburg-Prussia following the partition of the Duchy of Pomerania after the Treaty of Westphalia in 1648, and from the 18th century it formed part of the Kingdom of Prussia. On August 1, 1778, a blaze destroyed 18 houses which, however, were soon re-built. In 1871, the town became part of the German Empire. The first railway station was opened in 1878. The rails were transported by the sea and the bedding for the track was formed by sand taken from the dunes on the Western Beach. The first passenger train departed on 1 October 1878. The rail was also used as a main transport facilitating the trade from the harbour. The rail track was extended to run into the harbour, trading mostly grain and spirits. Records state that in 1887, the local harbour shipped 5 million litres of plain spirits. The Harbour lost its importance after World War II, as fishing began to take priority over trade.