Germany came from a goal down in Group F to hammer current title holders Portugal 4-2 with a fine attacking performance.
Germany thought they had taken an early lead through Gosens only for it be disallowed for offside. The hosts kept pressing causing Portugal problems but it was their opponents who took the lead against the run of play when a swift counter attack ended with Ronaldo on the scoresheet.
Portugal then came into the game only for Germany to rally with two late strikes at the end of the half through own goals from Diaz and Guerreiro.
Germany continued to torment a struggling Portuguese rearguard and Havertz made it three before star player Gosens got on the scoresheet with number four.
At this stage Portugal looked well beaten but found a way back into the game when Jota took advantage of some slack German defending.
Suddenly Germany became nervy but a revitalised Portugal were unable to capitalise although Sanches almost reduced the deficit further but his powerful long range effort struck the woodwork.
Portugal tried to force the game but were unable to involve Ronaldo enough and Germany looked comfortable defending, never looking like losing control of the game or the final result.
Portugal: 2 (Ronaldo 15, Jota 62)
Germany: 4 (Diaz og 35, Guerreiro og 39, Havertz 51, Gosens 60)
Man of the Match: Gosens