The Germans deserved to win after controlling most of the game, but remained frustrated until the Bayern Munich striker headed home Sami Khedira's cross 18 minutes from time. Joachim Lowe chose the prolific striker over Germany's second all-time scorer and Birthday boy Miroslav Klose, who has scored 63 goals, just five short of Gerd Muller's record of 68.
Portugal seem to have woken up pretty late, trying to level up in the final 10 minutes after sitting back and absorbing all the pressure thrown at them by the Mannschaft.
Portugese star Cristiano Ronaldo's international goal drought continued while his club teammate Fabio Coentrao was the most impressive player for the Iberians. Germany play-maker Mesut Ozil caused all sorts of problems in the Portugese box while Thomas Muller's infinite crosses from the right wing landed in no man's land on many occasions.
Hardly a minute into the game, Germans were likely to score when Gomez's header ended just wide of the goal. Portugal's left-back Coentrao ran down the middle but failed to complete the pass to Ronaldo. Germany's Mat Hummels intervened to stop the Real Madrid full-back.
Germans continued to push forward and through Ozil, Muller and Arsenal bound winger Lukas Podolski, Joachim Lowe's men were likely to go ahead before the half-hour mark.
Ronaldo was a spectator for most of the first half while Nani did not make any impact during the few chances they had on the break. When Ronaldo finally got hold of the ball, he managed to drive in cross beating full-back Jerome Boateng which resulted in a corner. Almost every Portugese attack ended in corners with 11 in total while Germans had just 2.
Ozil-Khedira linked together with a neat one-two to find Gomez in space inside the box, but French referee blew the whistle well in advance for a foul on Khedira by Raul Mereiles. The resulting free kick rammed into the wall.
Portugal finally got a clear-cut chance when defender Pepe found space in the box and curled a shot towards the top-corner. The ball hit the underside of the post, bounced onto the line and moved away.
Portugal began the second half with much more attacking intent. Nani found space on the right flank and beat Phillip Lahm to unleash a dangerous cross. Coentrao flew across the field to find Ronaldo free, but was denied a clear shooting opportunity as Boateng recovered to make a perfect block.
Manager Lowe was frustrated on the sidelines and ordered his troops to warm up as his men failed to break the deadlock. Klose was ready to come on for Gomez. But the 26-year-old Bayern Munich striker made his mark in what would be his last attempt of the match.
Khedira's cross deflected a defenders hand which sailed towards Gomez, who rose high to head it downwards which ended in the left corner of the goal. Klose was asked to sit back as Gomez had an opportunity to double the lead when Muller's cross was slightly ahead.
During the final 10 minutes, Portugese winger Varela replaced Mereiles. Portugese attack sprung into action when Coentrao's effort was deflected just over the bar before Nani's cross hit the bar and away.
Portugal's 20-year old striker Nelson Olivera controlled a long pass and chipped in a clever back heel to find Varela in the Germany box but Neuer was off in a flash to deny the winger.
Final chance came to none other than Ronaldo who found Nani inside the 6-yard box but his shot was deflected off Holger Badstuber.