The causes of WWI are very complex, however some of the main points were:
(I) The Alliance system which emerged in the 1890s, splitting Europe into two camps of Britain, France and Russia, and Germany, Italy and Austria-Hungary. Though it should be noted that only the latter alliance involved commitment to go to war.
(II) Disputes over imperialism between the Great Powers arguably fueled tensions leading up to 1914.
(III) The growth of militarism, exemplified by Britain and Germany's arms race before 1914, with both powers seeking to build the world's most powerful navy.
(IV) More reasons exist, but the final in this concise answer has to be nationalism, a 19th century movement which arguably drove up support for war amongst European peoples. A case in point would be the French nationalistic opposition to Germany due to the latter's possession of Alsace-Lorraine, one time a French province.