Why did the Germans never make a hard push and try to take Gibraltar during World War 2? In order to create a bottleneck for the allied ships wanting to enter/leave the mediterranean. I've heard of operations such as Operation Felix, however Operation Felix never left the early planning stage.
Couldn't Hitler have used the promise of returning Gibraltar to Spain to try and drag Spain in to the war?
To Germany the Med was an Italian theatre, where they were helping out. They generally resented the diversion of resources from their main concerns. But as the fighting continued and the Brtitish put in more resources, so did they.
The real thorn in the Med was not Gibraltar, but Malta. Not for from the coast of Sicily, it straddled the supply line into Africa and was an excellent support whenever the British 8th Army marched west. In early 1942, German diverted substantial resources to the Med to subdue Malta, bombing it with great intensity and bringing the island to a crisis. An invasion was planned and the forces marshalled, but Germany was wary of the operation because a) they had little skill or experience in opposed amphibious invasions, which are extremely difficult b) they would have to rely on their Italian allies to competently perform in the operation and c) the invasion of Crete, while ultimately successful, caused great loss to the invaders and had caused the Germans to view such operations with caution.
In the event, Rommel's success at the Battle of Gazala, and the paralysis of Malta when the Royal Navy abandoned its bases there, caused the Germans to instead support his advance and scrap the invasion of Malta, though one suspects they were happy to do this.
As for an invasion through Spain, Franco was always careful about antagonising the Allies. My father, an ex-RAF man, always maintained that fuel from Allied countries was sold through Spain to Germany, but I'm not sure how true this is.