The primary causes of World War I (1914-1918) were competition among industrial nations in Europe and diplomatic failures. As a result of nationalism, imperialism, and alliances, Europe was divided into competing camps that were well-armed.
The event that triggered the war occurred in the Balkan Peninsula when a Serbian nationalist assassinated the leader of Austria-Hungary, Archduke Ferdinand. After Austria-Hungary declared war on Serbia, the major European countries resolved to defend their allies with Austria-Hungary, Germany, and the Ottoman Empire making up the Central Powers, versus Serbia, Russia, France, and Great Britain, the Allied Powers.
Kaiser Wilhelm, the leader of Germany, aggressively expanded the war into surrounding countries, even if those areas were neutral. Germany was handily defeating Russia on its eastern front which exacerbated Russia's internal problems, such as food shortages. This lead to revolution in Russia and the country's subsequent exit from the war.
Germany’s aggressive submarine warfare against civilian ships combined with the Zimmermann Telegram, which showed Germany to be the enemy of the United States, pulled America into the war on the side of the Allied Powers. The U.S. provided the troops and supplies which helped turn the tide of the war against Germany.
Germany agreed to a cease-fire in 1918, but was shut out of the peace process at Versailles, where the Big Four representing Italy, France, Great Britain, and the United States met to write the peace treaty that ended the war. Instead of creating a stable, peaceful Europe, the Treaty of Versailles planted the seeds for another world war.