Flags of the Holy Roman Empire
In 1804, Napoleon Bonaparte declared the First French Empire. In response to this, Emperor Francis II of the Habsburg dynasty declared his personal domain to be the Austrian Empire and became Francis I of Austria. Taking the colours of the banner of the Holy Roman Emperor, the flag of the Austrian Empire was black and gold. Francis II was the last Holy Roman Emperor, with Napoleon forcing the empire's dissolution in 1806. After this point, these colours continued to be used as the flag of Austria until 1918.
Kingdom of Saxony
Before 1806, Saxony was part of the Holy Roman Empire, a thousand-year-old entity that had become highly decentralised over the centuries. The rulers of the Electorate of Saxony of the House of Wettin had held the title of elector for several centuries. When the Holy Roman Empire was dissolved in August 1806 following the defeat of Emperor Francis II by Napoleon at the Battle of Austerlitz, the electorate was raised to the status of an independent kingdom with the support of the First French Empire, then the dominant power in Central Europe. The last elector of Saxony became King Frederick Augustus I.