Spain raced into a 2-0 lead when Diego Costa stabbed past Sergio Romero before Isco side-footed his first goal.
Argentina, without injured forward Lionel Messi, pulled it back to 2-1 through Nicolas Otamendi’s header.
Isco and Thiago Alcantara extended the lead to 4-1, with substitute Iago Aspas adding the fifth before Isco completed his hat-trick.
Spain, the 2010 World Cup winners, are now unbeaten in 18 games since Julen Lopetegui took charge following their exit at the first knockout stage of Euro 2016.
They have two more friendlies, against Switzerland and Tunisia, before they launch their World Cup group campaign against European champions Portugal on 15 June.
Lopetegui’s side look a major threat on this evidence as they scored with all six shots on target.
Spain recorded their biggest win against a World Cup winning nation
Barcelona defender Gerard Pique, who supported the recent Catalan independence referendum, ignored jeers each time he touched the ball in Madrid’s Wanda Metropolitano to produce a solid performance at the back.
Andres Iniesta was outstanding in midfield, Isco showed his threat in front of goal as he became the first player since 2013 to score a hat-trick for Spain, and Aspas also did enough to suggest he should make the plane to Russia.
Problems pile up for Argentina
Argentina only secured a place at the World Cup on the final day of South American qualifying, a Messi hat-trick against Ecuador ensuring his country avoided missing a finals for the first time since 1970.
Messi watched this humiliating defeat from the stand as he sat out his second game inside a week after receiving treatment for a muscle injury.
Argentina boss Jorge Sampaoli has work to do to sort out a defence that was cut apart time and again in Spain’s capital.
Lionel Messi (right) reacts as Argentina capitulate against Spain
The two-time world champions were vulnerable to counter-attacks, and Chelsea goalkeeper Willy Caballero, a replacement for Manchester United’s Romero who was hurt trying to stop Costa’s goal, failed to inspire on his second appearance for his country.
Gonzalo Higuain was disappointing in front of goal as Otamendi proved Argentina’s biggest threat from set-pieces.
Argentina were also fortunate to finish with 11 men on the pitch as tempers boiled over near the end, prompting Premier League referee Anthony Taylor to blow the whistle on 90 minutes without any time added on.
Argentina conceded six goals in one match for the first time since 2009 when they lost 6-1 to Bolivia in a World Cup qualifier