The main incident that triggered ww1 was the assassination of Archduke Franz Ferdinand of Austria on June 28, 1914, in Sarajevo, the provincial capital of Bosnia-Herzegovina (formally annexed by Austria-Hungary in 1908).
Gavrilo Princip, a Serbian nationalist and member of the Black Hand, shot and killed both the Archduke and his wife, Sophie. The assassination was immediately condemned throughout the world, particularly in Austria-Hungary and Serbia.
Austria-Hungary blamed the Serbian government for the assassination and issued a series of demands to Serbia that were designed to humiliate and weaken the country. Serbia refused to accept all of the demands, which led to Austria-Hungary declaring war on Serbia on July 28, 1914.
The Russian Empire, as Serbia's ally, began mobilizing its military in support of Serbia. Germany, as an ally of Austria-Hungary, then declared war on Russia and France, Russia's ally. As a result, the conflict quickly escalated into a wider European conflict that became known as World War I.