For the European countries involved, a "fuse" was lit, running round them. Austria declared war on Serbia over the Sarajevo assassination - Serbia, threatened by a powerful enemy, invoked its Treaty with Russia - Austria, now faced by a powerful enemy, invoked its Treaty with Germany - Russia, now faced by a more powerful enemy, invoked its Treaty with France ....... Germany, to get its nearest enemy out of the way, then attacked France.
Unlike the European Powers, Britain had no Treaty obligations which required it to "take sides" when the war broke out. From historical precedent, it would seem most likely that its sympathies would be with the Central Powers, once Austria had brought Germany into the conflict, but that its interests would be best served by avoiding direct involvement, and letting the Europeans "fight it out amongst themselves".
That, however, was not how Britain saw it.
The unified Germany was the old ally, Kingdom of Prussia, but "writ large". Its rapid and efficient industrial development was already challenging Britain's manufacturing supremacy, its consequent requirement for secure sources of raw materials meant that it was building up an overseas Empire in East and South-West Africa and the Pacific, and, most challenging of all, it was building a powerful Navy to protect its trade routes, with modern warships, which outclassed many of those in the Royal Navy.
An "identical twin" was appearing, and there wouldn't be room in the world for both.
So, if a war with Germany was inevitable, then better now, with Allies, and while the German Navy was still in its infancy.
But, in the absence of any Treaty obligation, a pretext was needed, and this was found in a century-old Agreement between Britain, France and Prussia that, in any future European conflict, the neutrality of war-torn Belgium would be preserved. So, when Belgium refused a German request to allow the passage of its troops to attack France, and the German Army proceeded to force its way through regardless, this was the "scrap of paper" which, in July 1914 - and to the amazement and horror of the German Ambassador - Britain used to justify its involvement - on the French side !
And that, of course, brought in the world-wide Empire ......