In 1809, Napoléon had Württemberg commit troops for his war against Austria, while safeguarding its own eastern borders. Frederick William received the command of the troops deployed for border defence. At Napoleon's Russian campaign, Frederick William was again in command of troops. The campaign was devastating for the Württemberg army. Of the 15,800 soldiers, only a few hundred returned to Württemberg. After the Battle of Leipzig from 16 to 19 October 1813, Württemberg moved to the side of the alliance against Napoleon. Frederick William then took over the command of the Army of Württemberg, which was reinforced by Austrian troops in November. On December 30, the army crossed the Rhine at Hüningen.