Nationalism and imperialism were two of the causes. Europe’s major powers were trying to protect themselves and they distrusted one another, so they were continually shifting alliances. At the same time, there was a large armaments race driven by competition and the struggle for international stature. This armaments race and military planning only heightened the suspicion and fear brewing among the nations. It also made national leaders feel ever more dependent on their allies in case of war. They had joined alliances and felt bound by them, so they got into a war that they might not have entered on their own. Here is what happened:
i. Archduke Ferdinand of Austria-Hungary was killed and Austria-Hungary believed that Serbia had something to do with it, so they wanted to crush Serbia.
ii. Germany was an ally of Austria-Hungary and promised to take their side and help them if they needed it.
iii. Russia was an ally of Serbia, so they declared war on Austria-Hungary, so Germany declared war on Russia.
iv. Germany knew that France would not stay out of a war between Germany and Russia, so Germany declared war on France also.
v. Germany wanted to surround France, but to do so they had to go through Belgium. They asked permission and Belgium said no, so Germany declared war on Belgium too.
vi. Great Britain was an ally of Belgium, so they declared war on Germany. And so began WWI.
Europe maintained peace since Napoleon's time by keeping a balance of power between nation-states. Eventually these alliances became hopelessly complicated and entangled. They kept European powers from invading each other, but the struggle between countries to expand played out through the acquisition of colonies outside Europe. Within Europe, Nationalism rose between European businesses competing to expand markets, and culturally, by a desire to see one's own culture imposed upon one's neighbors. Thus it was understood that, for example, that a Frenchman would become a German once "liberated" from oppressive French concepts, and vice-versa. In order to compete with French and English colonies, Germany decided to build a "Middle Europe" empire stretching from the Baltic to the Middle East, which meant imposing German Ideals among Slavic populations. Within the less-stable countries, notably Austria-Hungary ("known as "the Sick Man of Europe") the many different ethnic groups within the country itself wished to establish their own political identity and independence, and thus contributed to the rise of Nationalism by freeing themselves from Germanic influence. When the political conflict between Serbia and Austria-Hungary, or cultural conflict between Slavic and Germanic, exploded in 1914, the "Entangling Alliances" brought the major European powers to war with each other.
we can trecy far back in Germany unification which led Franco-Prussian war of 1870's which led the following.
1.formation of millitary allience like Tripple Entete and Tripple Allience..ehuch later contribute in war.
2.European unbalance of power when Frence defeated by Prussian and lost two province Alsace and Lolein.Thus in order to recover French have to come Africa to expand.