Italy was officially a member of the Triple Alliance with Germany and Austria-Hungary. Despite this, in the years before the war, Italy had enhanced its diplomatic efforts towards the United Kingdom and France.
This was because the Italian government had grown convinced that support of Austria (the traditional enemy of Italy during the 19th century Risorgimento) would not gain Italy the territories it wanted: Trieste, Istria, Zara and Dalmatia, all Austrian possessions. In fact, a secret agreement signed with France in 1902 sharply conflicted with Italy’s membership in the Triple Alliance.
A few days after the outbreak of the war, on 3 August 1914, the government, led by the conservative Antonio Salandra, declared that Italy would not commit its troops, maintaining that the Triple Alliance had only a defensive stance and Austria-Hungary had been the aggressor. In reality, both Salandra and the minister of Foreign Affairs, Sidney Sonnino, began to probe which side would grant the best reward for Italy’s entrance in the war. Although the majority of the cabinet (including former Prime Minister Giovanni Giolitti) was firmly against intervention, numerous intellectuals, including Socialists such as Ivanoe Bonomi, Leonida Bissolati, and, since 18 October 1914, Benito Mussolini, declared in favour of intervention, which was then mostly supported by the Nationalist and the Liberal parties.
Pro-interventionist socialists believed that, once that weapons had been distributed to the people, they could have transformed the war into a revolution.
The diplomatic moves led to the London Pact (26 April 1915), signed by Sonnino without the approval of the Italian Parliament. According to the Pact, after victory Italy was to get Trentino and the South Tyrol up to the Brenner Pass, the entire Austrian Littoral (with Trieste), Gorizia and Gradisca (Eastern Friuli) and Istria (but without Fiume), parts of western Carniola (Idrija and Ilirska Bistrica) and north-western Dalmatia with Zara and most of the islands, but without Split. Other agreements concerned the sovereignty of the port of Valona, the province of Antalya in Turkey and part of the German colonies in Africa.
Germany and Austria-Hungary had only advanced the possibility of negotiating parts of the Trentino and Eastern Friuli, without Gorizia and Trieste. The offer of the French protectorate of Tunisia was deemed unsatisfactory.
Under the London Pact, Italy joined the Triple Entente. 3 May 1915 Italy officially revoked the Triple Alliance. In the following days Giolitti and the neutralist majority of the Parliament opposed declaring war, while nationalist crowds demonstrated in public areas for it. (The nationalist poet Gabriele D’Annunzio called this period le radiose giornate di Maggio—”the sunny days of May”). On 13 May Salandra offered his resignation to King Victor Emmanuel III, but Giolitti, fearful of nationalist disorder that might break into open rebellion, declined to succeed as prime minister and Salandra’s resignation was not accepted. On 23 May, Italy declared war on Austria-Hungary. This was followed by declarations of war on the Ottoman Empire (21 August 1915, following an ultimatum of 3 August), Bulgaria (19 October 1915) and the German Empire (28 August 1916). [Wikipedia]