Tallinn has been known by several names throughout its history. It began as a Finno-Ugric settlement along the Gulf of Finland over 3,500 years ago. In the 11th century, it became an important port and marketplace for Scandinavian and Russian merchants. Tallinn came under Danish rule in 1219 and flourished as a trading city in the 14th-16th centuries as a member of the Hanseatic League. It later became part of Sweden and then the Russian Empire before gaining independence in 1918. Tallinn is now the capital of Estonia and a modern center of business and technology.