The first historical records on Aalst date from the 9th century, when it was described as the "villa Alost", a dependency of the Abbey of Lobbes. During the Middle Ages, a town and port grew at this strategic point, where the road from Bruges to Cologne crossed the Dender. While it was within the Holy Roman Empire it was considered the capital of the province of Flanders. In 1046, Aalst was transferred to the Countship of Imperial Flanders, and absorbed a portion of Brabant, and in 1173 it was united with the remainder of the Flanders province. Its frontier position on the border of the Holy Roman Empire allowed the town to keep a certain degree of independence. Its relation with Brabant has been preserved in the city's white and red coat of arms, the colours of Lotharingia.