The Treaty of Ilbesheim between Austria and Bavaria was signed on 7 November 1704, three months after the Battle of Blenheim. It had the effect of removing Bavaria from the War of the Spanish Succession. By the terms of the treaty, Bavaria was essentially placed under military occupation by Austria and the Palatinate, and remained so until the Treaty of Baden in 1714.