World War I, which lasted from 1914 until 1918, introduced the world to the horrors of trench warfare and lethal new technologies such as poison gas and tanks. The result was some of the most horrific carnage the world had ever seen, with more than 16 million military personnel and civilians losing their lives.

It also radically altered the map, leading to the collapse of the sprawling Austro-Hungarian, Ottoman and Russian empires that had existed for centuries, and the formation of new nations to take their place. Long after the last shot had been fired, the political turmoil and social upheaval continued, and ultimately led to another, even bigger and bloodier global conflict two decades later.

The event that sparked the conflagration was the assassination of the heir to the Austro-Hungarian Empire, Archduke Franz Ferdinand, in 1914. But historians say that World War I actually was the culmination of a long series of events, stretching back to the late 1800s. The path to war included plenty of miscalculations and actions that turned out to have unforeseen consequences.

“No one can say precisely why it happened,” explains the narration to a film at the National World War I Museum and Memorial in Kansas City. “Which may be, in the end, the best explanation for why it did.”

Here are eight of the events that led to the war.

1. Franco-Russian Alliance (1894)

Both Russia and France, which had been humiliated in the Franco-Prussian War of 1870-71, feared the rising power of Germany, which had already formed alliances with Austria-Hungary and Italy. So the two nations decided to join forces for mutual protection as well. It was the start of what would become the Allied side, the Triple Entente, in World War I.

“To my mind, it is the coming together of the Triple Entente in stages—the Franco-Russian Alliance in 1894, the British-French Entente Cordiale of 1904, and the Anglo-Russian Entente of 1907—that really solidified the system of diplomatic agreements that formed the main antagonistic blocs that went to war in 1914,” Richard S. Fogarty, an associate professor of history at University at Albany, explains. “The alliance system was critical to shaping the war, and even in helping bring it on: it created a set of expectations about international rivalry and competition, determining what kind of war Europeans imagined and prepared for.”

WATCH: World War I Alliances

2. First German Naval Law, (1898)

This legislation, advocated by Germany’s newly-appointed Secretary of the Imperial Navy, Admiral Alfred von Tirpitz, dramatically expanded the size of Germany’s battle fleet. It was the first of five laws dictating a buildup in which the Germans envisioned building a force that was superior to Britain’s Royal Navy.

“Tirpitz aimed at forcing Britain into an alliance with Germany on German terms,” explains Eugene Beiriger, an associate professor of history, peace, justice and conflict studies at DePaul University, and author of the 2018 book World War I: A Historical Exploration of Literature. Instead, the British responded by building even more ships, and by ending their late 1880s policy of “splendid isolation” to form alliances with Japan, France and Russia.

“The German Naval Laws created unintended consequences,” Beiriger says in an email. “They ended up alienating both the government and public of Britain prior to the war.”

HISTORY Vault

3. The Russo-Japanese War (1904-1905)

Russia’s Czar Nicholas II wanted to obtain a port that gave his navy and commercial ships access to the Pacific, and he set his sites on Korea. The Japanese saw Russia’s rising aggressiveness as a menace, and launched a surprise attack on Nicholas’ fleet at Port Arthur in China. The resulting war, fought both at sea and on land in China, was won by the Japanese, and as Beiriger notes, it helped shift power the power balance in Europe.

Russia’s allies France and Britain, which were allied with Japan, signed their own agreement in 1904 to avoid being pulled into the war. France later convinced the Russians to enter into an alliance with the British as well, laying the groundwork for their alliance in World War I. In addition, “Russia's expansion in the East had been stopped by Japan,” Beiriger says. “This turned Russian ambitions westward, especially in the Balkans, and influenced hardliners within the government to not back down in future crises.” That Russian combativeness helped trigger World War I less than a decade later.

4. Austria-Hungary’s Annexation of Bosnia and Herzegovina (1908)

ullstein bild/Getty Images
A train packed with soldiers leaves a railway station&nbsp;<em>during the Bosnian annexation crisis in 1908.&nbsp;</em>

Under an 1878 treaty, Austria-Hungary was governing Bosnia and Herzegovina, even though technically they were still part of the Ottoman Empire. But after Austro-Hungarian government annexed their territory, the move backfired. The two provinces’ mostly Slavic population wanted to have their own country, while Slavs in nearby Serbia had the ambition of appropriating the provinces themselves.

“In multi-ethnic empires, nationalistic fervor fueled resistance to distant rulers,” Doran Cart, senior curator of the National World War I Museum and Memorial, says. “Tension was powder-keg high in the Balkans, where Slavic people, aided by the Slavs of Russia, resisted the rule of Austria-Hungary.” Additionally, the move drew Russia, which saw itself as Serbia’s protector, toward a gradual showdown with the Austro-Hungarian regime.

5. The Second Moroccan Crisis (1911)

Second Moroccon Crisis
ullstein bild/Getty Images
The German small cruiser SMS Berlin is shown arriving two days after gunboat Panther in order to strengthen the German position off shore Agadir, Morocco, July 1911.

The French and Germans butted heads for several years over Morocco, where Germany’s Kaiser Wilhelm II meddled in an attempt to pressure the French-British alliance. In the First Moroccan Crisis in 1905, he actually sailed to Tangiers to express his support for the sultan of Morocco against French interests. But instead of backing away from the conflict, the British rose in support of France.

In the Second Moroccan Crisis in 1911, the German foreign secretary, Alfred von Kiderlen- Wächter, sent a naval cruiser to anchor in a harbor on the Moroccan coast, in reaction to a tribal revolt that the Germans thought was being backed by France as a pretext for seizing the country. Again, the British backed the French, and eventually, Germany was forced to agree to recognize a French protectorate in Morocco. The two crises pushed the British and French closer together, and only hastened an eventual confrontation with the Germans.

6. Italy Invades Libya (1911)

Universal History Archive/Universal Images Group/Getty Images
The Italian government declared war on Turkey in 1911 because it had refused to permit the military occupation of Tripoli by Italy. Italian troops are seen here landing after the bombardment of Benghazi.

The modern Italian state, which didn’t begin until 1861, had been “largely left out of the scramble that built Britain, France, and other powers into worldwide empires,” Fogarty explains. The Italian government set its sights on Libya, a North African country that hadn’t been claimed by another western European power, and decided to take it from the Ottoman Empire. The Italo-Turkish War ended with a peace treaty, but the Ottoman military left Libya and let the Italians colonize it. It was the first military conflict that featured aerial bombing, but as Fogarty notes, the real significance was that it exposed the shakiness of the Ottoman Empire and its slipping control over peripheral territories. That, in turn, was one of the factors that ultimately led to World War I, which Fogarty describes as “a war of empires, some expanding or seeking to expand, some keen to hold on to what they had, others trying desperately not to lose what they had left,”

7. The Balkan Wars (1912-13)

Balkan War soldiers
Topical Press Agency/Getty Images
Soldiers resting with their weapons off a battlefield during the Balkan Wars.

Serbia, Bulgaria, Montenegro and Greece, which had broken away from the Ottoman Empire during the 1800s, formed an alliance called the Balkan League. The Russian-backed alliance aimed to take away even more of the Turks’ remaining territory in the Balkans.

In the First Balkan War in 1912, Serbia, Greece and Montenegro defeated Ottoman forces, and forced them to agree to an armistice. But the Balkan League soon disintegrated, and in the Second Balkan War, the Bulgarians fought the Greeks and Serbs over Macedonia, and the Ottoman Empire and Romania jumped into the fray against the Bulgarians as well.

Bulgaria ultimately was defeated. The Balkan Wars made the region even more unstable. In the power void left by the Ottomans, tensions grew between Serbia and Austria-Hungary. That, in turn, led Austria-Hungary and its ally, Germany, to decide that a war with the Serbs would be needed at some point to strengthen Austria-Hungary’s position. “Many historians consider the Balkan Wars as the true beginning of the First World War,” Fogarty says.

8. Assassination of Archduke Franz Ferdinand (1914)

WATCH: How a Wrong Turn Started World War I

The archduke, who was heir to the Austro-Hungarian throne, went to Sarajevo to inspect the imperial troops stationed in Bosnia and Herzegovina. He and his wife Sophie were shot to death in their car by a 19-year-old Serbian revolutionary, Gavrilo Princip.

“The assassination highlighted the nationalism that was pulling the Austro-Hungarian Empire apart at the seams,” Fogarty explains, noting that Serbian extremists actually wanted Franz Ferdinand dead because they feared he was too moderate and would promote a power-sharing arrangement that would keep Slavic peoples in the empire.

“His assassination killed the idea, whether or not it was ever realistic to begin with, and radicalized Serbian defiance and Austrian determination to solve the nationalism problem for good, at least with respect to Serbia,” Fogarty says.

Instead, the tension between European powers increased, as they took different sides in the crisis. As the U.K.’s Imperial War Museum notes, the killing put both Austria-Hungary and Russia, which saw itself as the Serbians’ protector, in a bind. Neither one of them wanted to back down and appear weak. Fearing a fight that would draw in Russia, Austria-Hungary turned for help to Germany, which promised backing if the Austro-Hungarians used force against the Serbians. German support emboldened Austria-Hungary to declare war on Serbia on July 28.

Two days later, Russia’s military mobilized, and the Germans saw that they too were in a bind. They didn’t want to fight both Russia and its ally France on two fronts simultaneously, so it became imperative to knock the French military out of the war before Russia was ready to fight. Germany declared war on Russia on August 1, and two days later declared war against France. German forces gathered on the border of neutral Belgium, which they planned to cross in order to invade France. Belgium called for help, and on August 4, Great Britain declared war on Germany. 

World War I had begun.