To be precise I think it is wrong to say that Frederick failed in Otl, rather it is more correct to say that he had to face a complex series of adversities, which his political opponents knew how to skilfully exploit against him, first of all, he inherited a kingdom and an Empire with enormous problems : in Sicily, you have to deal with the nobility trying to regain the previous political authority lost to the detriment of the young sovereign, and the various Saracen revolts in the hinterland ( which lasted until 1221 / 23 ) in the HRE instead you have to deal with the struggle between Guelphs and Ghibellines ( with even fighting to regain the crown Imperial taken away from his family by Otto IV, which further weakened the central government ( caused by the early death of Henry VI and the rivalry between Philip and Otto, which lasted for 17 years ) , in favor of the princes ( 1 ) in Italy he was forced to fight the Italian municipalities ( in particular the Lombard league and Milan ) finally it must be considered that his dominions surrounded the state of the church, causing a certain fear in the papal curia ( the same thing happened following Charles V ) until he had a friendly Pope ( Innocent III, who had been his guardian and godfather ) everything went well, but when found himself with a Pontiff who was wary of him, things began to get worse ( this is also because Federico had to deal with the management of an immense state ( and with different laws, traditions and languages ) in a period in which the bureaucracy was in its embryonic state and without any relative or trusted man to help him ( unlike Charles V ), it must also not be forgotten that in this era the royal power was tangible only in the physical presence of the Monarch in a specific region, therefore we can understand that his ability to actively influencing some areas of his Empire were very limited ( which especially in Germany was noticed quite quickly ) to conclude I believe that we perceive Frederick's reign as a total failure only because his dynasty became extinct ( even if due to machinations policies ) and both Sicily and HRE went through decades of internal conflict, when in reality things were much more nuanced, and with the right changes the story would have taken a markedly different path, Furthermore, Frederick himself was responsible for some of his problems, as he wasted several opportunities to strengthen his government ( 2 )
1 ) without forgetting that the only time in which Frederick tried to implement a policy with the aim of weakening the princes, they managed to turn them against his firstborn Henrich and unleash an internal revolt, making him understand definitively that to govern in Germany it was necessary to obtain their favor ( which was also very useful for his Italian campaigns )
2 ) for example, among the various wasted opportunities, there was that Frederick, who, not taking advantage of Innocent IV's escape from Rome towards Lyon, if could easily enter the city and create his own antipope or occupy the city with the consent of the SPQR, and use the resources of the Papal State for its fight against the Lombard League or after the victory at Cortenuova, try to obtain the coronation as King of Italy in Pavia ( which he did not have in OTL ) which would have given him a little more advantage, or another opportunited are a well as trying to regain the Duchy of Spoleto and the March of Ancona