Germany secured third place in the World Cup courtesy of an entertaining 3-2 win over Uruguay in Port Elizabeth. A Sami Khedira header settled a game that saw both Thomas Muller and Diego Forlan move onto five goals for the tournament.
Muller currently leads the race after his fifth goal of the tournament - the same as Diego Forlan, David Villa and Wesley Sneijder but with more assists. Villa and Sneijder play in Sunday's final but Muller, the outstanding young player of the tournament, set the target in only his eighth appearance for Germany.
Muller opened the scoring in a rain-soaked Port Elizabeth before Edinson Cavani equalised for Uruguay, then Diego Forlan volleyed the South Americans in front before a goalkeeping error allowed Marcell Jansen to equalise.
A thrilling game - the most open contest of the World Cup - was finally decided when Sami Khedira headed home to give Germany their second third-place finish in consecutive tournaments.
Germany's hopes had looked dented when Miroslav Klose - who could have broken Ronaldo's all-time scoring record of 15 World Cup goals - was ruled out by a back injury. Muller was back from suspension however, as was Luis Suarez, the man whose controversial handball prevented Ghana from reaching the semi-finals.
It was Germany who seized control of the match in the opening exchanges with Cacau having a goal ruled out and Arne Friedrich thumping a header against the crossbar.
Germany made their dominance tell in the 19th minute when Bastian Schweinsteiger let fly from 30 yards and Uruguay keeper Fernando Muslera misjudged the shot, allowing Muller to tuck home the loose ball with a minimum of fuss.
That should have been the cue for Joachim Low's side to impose their game on the South Americans but instead Schweinsteiger, their skipper and inspiration all tournament, allowed himself to be caught in possession by Diego Perez and suddenly it was the Germans being hit on the break.
Suarez's perfectly-timed pass put Cavani through on the left and he finished expertly low into the far corner to put Uruguay on level terms in the 28th minute.
Suarez, the striker who has been so deadly for Ajax, spurned an excellent chance to seize the lead when he fired wide late in the first half. The same player was denied again in the second by a reaction block from Hans-Jorg Butt, seconds after he had thwarted Cavani, but Germany's keeper could do nothing when Forlan's first-time shot from the edge of the box.
Egidio Arevalo muscled his way down the right and Forlan met his cross on the volley, the ball bouncing down into the ground and whistling into the net with Butt helpless.
But just when Uruguay looked on top another goalkeeping blunder allowed Germany back into the game. Muslera came for Jerome Boateng's cross but missed it completely, allowing Jansen to head into an empty net.
Butt kept Forlan at bay while at the other end substitute Stefan Kiessling twice came close to restoring Germany's lead.
With eight minutes left Mesut Ozil's corner caused chaos in the Uruguay area and Khedira looped a header into the corner to make it 3-2.
Kiessling scooped over from a great position before, with the very last kick of the game, Forlan blasted a free-kick against the frame of the goal.