Of course there were some good reasons for an invasion of Italy as an addition to the eventual invasion of France, but how was the notion that Italy was an easy route into the rest of Europe justified?
Of course the Italian army was famously not terribly capable (albeit far from completely incompetent, as some people seem to think), but the Germans would undoubtedly have reinforced them, and the Italian peninsula is a long, narrow, mountainous funnel, ideal for defensive warfare and with little space to execute large-scale encirclement movements, which had been proven to be effective time and time again on the eastern front.
And even if the peninsula could be taken without the Axis having to spread their forces out to defend France as well (which it probably could have, just with great difficulty and losses), the path to Germany still wouldn't exactly have been easy, given that the peninsula is practically entirely cut off from the rest of Europe by the formidable and easy-to-defend alps.
Well at this time it would not have been practical to attempt to invade some of the more ambitious targets the allies may have sort to pursue in places like the France.
The resources that would have been required for such an invasion, as had to be invested into the D-Day landings were significant and operation overlord took a lot of preparation. However it was necessary to provide the Soviets with proof of the commitment of the western allies to continue offensive action in Europe after the end of the North African, Syrian, East African ect campaigns. Along much of the coast of the north sea, channel coast and atlantic the Germans had been in the process of building the Atlantic wall which made amphibious landings significantly more difficult there.
The italian coastline had much less permanent fortifications defending it so it was considered likely to be the easier option i terms of getting some initial beach heads on shore. It turns out that in the end some of the beach heads like near Salerno faced more resistance on the beach itself than was expected and the Germans counter attacked there and Anzio which resulted in heavier casualties than expected but still talking 5x lower than Overlord or so here. And that helped teach the allies some lessons which probably helped a lot on D-Day.
Similarly the allies correctly estimated that many Italians including elements of the Italian army and crown were increasingly running out of patience with Mussolini's failures and that they would fold when pressure was placed on them that directly threatened the Italian homeland meaning the ability of the Italians to contribute to the war effort.
The allies didn't have much faith that the Italy was a path to reach Berlin but it was a front they could open up quickly. While the Italian campaign did include more of a case of steadily pushing through defensive lines one by one, only really very late in the war as the German forces fell apart was things like the encirclement of Bologna possible. But the allies were as i said earlier causing Axis forces to be removed from the fighting in other ways over the course of the conflict. Firstly many of the troops after Mussolini was arrested for the first time ended up spending the rest of the war i German POW camps, some joined the allies or resistance groups and many of those Italian soldiers that did keep fighting ended up being occupied fighting those resistance groups along with other German forces that were tied up in the end occupying the puppet government they were forced to make in order to keep hold of northern Italy.
Another thing to keep in mind is that Italy could have been used potentially for other invasion routes other than via the Alps should that have been an option that was required. For example operation Dragoon in southern france was conducted part from the Italian mainland and part from Corsica who's liberation had been facilitated in part by the fall of Italy.