Question: Operation Felix was the seizure of Gibraltar (a British naval base at the tip of the Mediterranean Sea) by the Nazis during World War 2. The Nazis believed if they could take control of Gibraltar, which was strategically important, they could take control of the Mediterranean and invade French North Africa. It seemed like the plan was going to go forward, but it was stopped. What happened?

Answer: 
**In short, without wholehearted Spanish support, taking Gibraltar would have cost too much militarily and Franco wanted the rock for Spain.** Having it change from British hands to German ones really didn't serve Spanish interests. Further, Franco was concerned about losing the Canary Islands to the Royal Navy if Spain did not remain neutral.

---

There were quite a number of reasons why Operation Felix (and later Felix-Heinrich) was not carried out, most of them covered in the [Wikipedia article](https://en.wikipedia.org/wiki/Operation_Felix). These are elaborated on and supplemented by the links provided in the comments on the OP and on *Tomas By*'s post. There is little point in repeating them here, but one point worth emphasizing is that **[Franco](https://en.wikipedia.org/wiki/Francisco_Franco) wanted Gibraltar under Spanish control**, not German. 

The then Spanish Interior Minister [Ramon Serrano Suner](https://en.wikipedia.org/wiki/Ram%C3%B3n_Serrano_Su%C3%B1er)

> 
> recalls that after the downfall of France, Franco and virtually all his Generals had 'blind faith' in a German victory and **were impatient to occupy the Rock**
> 
> 
> 

*Source: Joe Garcia, '[Operation Felix](https://books.google.com.ph/books/about/Operation_Felix.html?id=wqelMwEACAAJ&redir_esc=y)' (1979)* (my highlighting)

On the other hand, according to the historian Sir [Llewellyn Woodward](https://en.wikipedia.org/wiki/Llewellyn_Woodward), Franco

> 
> ...wished to maintain Spanish independence, and therefore had no particular interest in helping to bring about an overwhelming German victory, still less a victory in which Italy would also put forward claims in the Mediterranean
> 
> 
> 

*Source: Garcia*

Further,

> 
> Franco was later to make it known that...Gibraltar had to be captured with Spanish troops, which in itself clashed with German intentions
> 
> 
> 

*Source: Garcia*

According to [Ribbentrop](https://en.wikipedia.org/wiki/Joachim_von_Ribbentrop), Franco also feared reprisals (e.g. losing the [Canary Islands](https://en.wikipedia.org/wiki/Canary_Islands)) from Britain if Spain helped Germany.

Thus, it is not hard to see why Hitler found Franco so stubborn about not letting German troops into Spain. Franco wanted an Axis victory, but not to the extent that it might compromise Spanish interests. Without Spanish cooperation, Operation Felix was pretty much a non-starter as the military costs for Germany would have been too high. Likewise, [Operation Felix-Heinrich](https://en.wikipedia.org/wiki/Operation_Felix) never happened due to reversals on the Eastern front.
One possible explanation is that [the British bribed Franco](http://www.telegraph.co.uk/news/worldnews/europe/spain/3199591/Winston-Churchill-bribed-General-Franco.html) to stay out of the war.

> 
> Churchill apparently convinced Spanish banker Juan March to act as a
>  secret agent, organising payments of millions of dollars to Franco's
>  generals in return for Franco agreeing not to side with Hitler
> 
> 
>