Manchester City winger Ferran Torres scored his first career hat-trick as Spain inflicted Germany’s heaviest competitive defeat and joined France in the four-team Nations League finals.
In a repeat of the Euro 2008 final, former Chelsea forward Alvaro Morata headed home Spain’s first goal, before Torres volleyed home emphatically.
Rodri made it three with a guided header, and Torres slotted in a fourth before curling home the fifth.
Mikel Oyarzabal’s tap-in made it 6-0.
Spain and France will be joined by either Belgium or Denmark from Group A2 and Italy, the Netherlands or Poland from Group A1.