Serbia gained considerable internal autonomy from the Ottoman Empire in two uprisings in 1804 (led by Đorđe Petrović – Karađorđe) and 1815 (led by Miloš Obrenović). Ottoman troops continued to garrison the capital, Belgrade, until 1867. The Serbs launched not only a national revolution but a social one as well. Complete independence arrived in 1878. Serbian activists promoted ethnic nationalism in the Balkans, targeting both the remnants of the Ottoman Empire and the equally fragile Austro-Hungarian Empire. The Serbia followed Montenegro against the Ottomans, and one full independence from the Congress of Berlin in 1878. Serbia played a central role in the Balkan wars of the early 20th century, which practically eliminated the Ottoman presence in Europe