Enns was granted a municipal charter by Duke Leopold VI, of the ruling house ofBabenberg, on April 22, 1212, making it the first city in Austria to be legitimized by noble fiat. Enns was granted its charter ahead of Linz, Salzburg, and Vienna. Though Enns was an important port in the Middle Ages, located at the end of the ancient "iron road" from Steyr and the port at which salt and iron from the southern regions were transhipped by way of the Danube to the east and west, Enns, even then, was not the wealthiest or largest city in Austria. But it was then, as it is today, located on a natural border to two frontiers. The River Enns has marked the spot at which marches of invaders from the east have stopped, a natural border between the Slavs in the east and the Germans in the west. In 791, again in 901, and as recently as 1945, the river has been a dividing line. Though the oldest known settlement here was Roman, placed on the south bank of the Danube as a bulwark against the barbarians in the north, the place was probably occupied long before the Romans arrived.