The Ottoman Empire began in 1299 in present-day Turkey and gradually expanded through conquest over the following centuries to control large portions of Europe, Africa, and Asia. At its peak under Suleiman the Magnificent in the 16th century, the empire encompassed Southeast Europe, Western Asia, the Caucasus, North Africa, and the Horn of Africa. However, the empire then began a long period of decline due to overextension, economic troubles, and military defeats. It allied with the German Empire and Austria-Hungary in World War I but was defeated, and the empire was dissolved in the War of Independence and Treaty of Lausanne in 1922-1923.