The Reds' number 17 - who also wears that shirt for his country - created the winning goal for his former club colleague Cristiano Ronaldo 17 minutes from time. With the Portuguese on a lightning counter-attack, Nani rolled the ball into the area for the Real Madrid star to turn inside Gregory Van Der Wiel and pick his spot past Maarten Stekelenburg. In the previous attack, the Dutch keeper denied Nani what should have been a certain goal from Ronaldo's slide-rule pass along the six-yard line.
Ronaldo also scored Portugal's other goal, a first-half equaliser to cancel out the early lifeline given to point-less Holland by Tottenham midfielder Rafael Van der Vaart. Both Ronaldo - missing out on a hat-trick - and Van der Vaart hit the woodwork in the latter stages of the game, during which Portugal coach Paulo Bento gave Nani a well-earned breather.
Nani and company go through as Group B runners-up and will face Czech Republic in the last eight. Table toppers Germany will take on Greece after winning all of their games at Euro 2012 so far. Their third victory - 2-1, courtesy of goals from Lars Bender and new Arsenal striker Lukas Podolski on his 100th cap - knocked out Denmark, for whom United goalkeeper Anders Lindegaard was again an unused substitute.