The idea that the First World War was inevitable is a popular supposition but, in my view, a largely unjustified one. Some sort of major European war was very likely indeed, but the alliances of Europe were much more fluid than the popular image of the First World War as some chain of rigid unbreakable alliances where everyone knew who the enemy was and then marched to war against those long-known opponents once the tripwire was sprung. The Franco-Russian Alliance started off as an alliance as much against the United Kingdom as against Germany! To give an example of this fluidity, the Anglo-Russian Convention was on the verge of breaking down; it was due to be renewed in 1915 and it probably would not have been because of Anglo-Russian tensions in Persia, to the extent that even the most Russophilic figure in the British Foreign Office was warning that a major change in the European diplomatic alignments was likely to take place. To give another example, the Schlieffen Plan which triggered the German invasion of Belgium would likely not have been carried out if the war had started later so Russia had had time to advance a few years and further her infrastructural and army development; add that to the fact that the confusion over the British stance was due in great part to the actions of one particular man, Sir Edward Grey, who may not still have been in power if the war had started later, and British entry to the war is hardly guaranteed, especially when considering that there were attempts at Anglo-German rapprochement. To give yet another example, Germany's entry to the war was triggered (and here I do deliberately say triggered, not caused) by Russia's idiotically inflexible mobilisation plans which were unable to mobilise against the Habsburg Monarchy without also mobilising against Germany; it is possible that Germany would have entered the war without Russia already mobilising against Germany as it did in OTL, but one cannot guarantee it, so any serious revision of the Russian general staff's mobilisation plans, which could very easily be imagined to take place if the war had been delayed by a little while and the diplomatic situation changed dramatically in 1915 with the non-renewal of the Anglo-Russian Convention, could have restricted the expansion of the war. To give yet another example, the alignment of Serbia and Romania towards the Triple Entente and Bulgaria and the Ottoman Empire towards the Central Powers was not set in stone, and indeed the diplomatic alignments of the Balkan states were shifting multiple times in the era leading up to the First World War. To give my final example, even if a major European war did start with a Habsburg-Serbian flashpoint (which does have a significant probability, given the efforts of Serbian-sponsored Serb and Yugoslav nationalists in Habsburg territory) it is still not inevitable that the war would resemble OTL's; a PoD as simple as the location of Wilhelm II at the time of the assassination could have had dramatic changes in European history, as OTL's Wilhelm II, upon hearing of the Serbian reply to the Habsburg Monarchy's ultimatum, sent a letter to Gottlieb von Jagow in Berlin, saying that he thought this was an excellent response, a diplomatic victory for the Habsburg Monarchy and removed any need for war and commanding that this be sent to Emperor Franz Josef; Wilhelm's government disagreed and instead gave the Habsburg Monarchy the infamous 'blank cheque' for war. It's true that there were certain constants in European diplomacy which could not reasonably be altered—Franco-German enmity, Russo-Ottoman enmity and Habsburg-Russian enmity for instance—but there were plenty of things which weren't. The fact that the war started as it did gave us a snapshot of European alliances at one particular moment, not a continuous perfect picture.
It is popular nowadays to suggest that the death of Franz Ferdinand was just a trigger for a conflict of a predetermined nature to break out when that conflict was shaped and formed by other reasons, but I don't believe the arguments for this stand up to scrutiny. In addition to the fluidity of European alliances which I have spoken of above, the death of Franz Ferdinand was not just a pretext for Germany and the Habsburg Monarchy, or Serbia and Russia for that matter, to gleefully carry out long-prepared war of aggression. Multiple sides genuinely did feel they were under threat by the aggression of their enemies. It's true that Emperor Franz Josef had little fondness for Franz Ferdinand, but the Habsburg Monarchy saw a conspiracy which they suspected (correctly) included elements high up in the Serbian government assassinating the heir to the throne of an empire held together by its monarchy at a time when the Emperor was very old and surely soon to die, and this is good reason to construe as an attempt against the existence of the Habsburg Monarchy itself. Given well-known Serbian opinion of the Habsburg Monarchy and the vast influence of the Black Hand in Serbia it was understandable for the Habsburg Monarchy to not trust the Serbian government to investigate the incident and bring the perpetrators to justice itself; and it was equally understandable for Serbia, defending its sovereignty, to refuse. The Russian Empire saw a Habsburg mobilisation against Serbia which it misconstrued as a mobilisation against both Serbia and Russia, due in part to poor intelligence. The Germans saw a Russian mobilisation against both the Habsburg Monarchy and itself, and therefore chose to mobilise themselves because a key advantage of theirs (dating back decades) was the speed of their mobilisation so they could not afford to delay it for political reasons if a war was imminent; perceiving apparent Russian aggression, the Germans told the French rather imperiously to not militarise their own border, which was an understandable request under the circumstances but, with Germany apparently preparing for war, looked to the French like a preparation for German aggression, so France, understandably, refused; and thus the assassination of an archduke turns to a war between France, Russia and Serbia on the one hand and the Habsburg Monarchy and Germany on the other hand, and broadens further. This was not the simple idea of a spark setting alight alliance-tripwires which thus set off the explosion of war, a war that would be the same regardless of where the spark happened to be, that some segments of the press like to imagine, nor was it the simple case of German/Serbian/whoever's nasty evil aggression that other segments of the press like to imagine; it was a series of diplomatic misunderstandings and failures that led to every side doing what it thought of as defending itself, where the shape of the war was determined in great part by the shape of the crisis that caused it.
I am not certain what sort of war might have broken out in Europe, and what the alliances of Europe might have been at the time it did, if there hadn't been one from the July Crisis, but I don't think it's as easy to predict as "Oh, the First World War would have happened sometime, count on it".