The Dutch side literally toyed with the holders to avenge their 2010 World Cup final defeat in Johannesburg as Robin van Persie and Arjen Robben both scored twice. Stefan De Vrij was the third scorer for the Dutch side in a dramatic contest.
It is worst defeat for Spain since its 6-2 thrashing at the hands of Scotland in 1963. It is also first time since 2002 that defending champions have lost the opening game.
France had lost to Senegal 0-1 in Seoul in 2002 but they were not mauled as badly as Spain were in this game.
In other matches, Mexico shrugged off two contentious off-side calls in the first half to beat Cameroon 1-0 in Group A at Natal while Chile scored an impressive 3-1 win over Australia in another Group B contest at Cuiaba.
Chile's win means that Spain's title defence has become even tougher as it will be a challenge for them to cross the first round and even if they do so, they may have to contend with formidable Brazil in the round of 16.
The stunning Dutch victory also eclipsed the controversy surrounding the match officials for their continued dubious decision. For the second day in running, a controversial penalty was awarded in the match between the top sides as Spain benefitted to take a 1-0 lead.
Referee Nicola Rizzoli ruled that Diego Costa had been fouled by De Vrij and Xabi Alonso had no problem in slotting the shot past Dutch goalkeeper Jasper Cillessen.
A stunning header from Manchester United forward Van Persie, 90 seconds before the break, on a pass by Daley Blind brought the sides on level terms and what followed in the second half was complete Dutch domination.
Eight minuets into the second half, Blind fed Bayern Munich striker Robben, who beat two rival defenders to give his side a 2-1 lead. Centre-half De Vrij threw the World champions in a tizzy as got his name on the scoresheet by heading one home in the 64th minute.
Four minutes later, Spain almost pulled one back when David Silva put the ball over the line as Cillessen could not hold Pedro's header but he was offside.