Spain left Johannesburg with their tails between their legs after falling to a stunning 1-0 loss to South Africa.
The home side were deserving winners at Soccer City, with Vicente del Bosque's side disjointed throughout.
After a first half of few chances, Bernard Parker struck the only goal of the game after latching on to a through ball and finishing well.
Goalkeeper Victor Valdes had entered the game at half-time, but was forced from the pitch with a painful looking knee injury that forced him from the field.
Del Bosque made 10 changes to the side that edged past Equatorial Guinea 2-1 on Saturday. Xabi Alonso was the only man retained, while four of South Africa's XI from their 3-0 triumph over Swaziland were again picked by Gordon Igesund.
Spain looked to exploit the hosts' high defensive line with David Villa finding the net twice in the opening seven minutes - only to see both efforts ruled out by the offside flag.
South Africa grew in confidence after their shaky start and almost took the lead through Oupa Manyisa in the 17th minute.
The Orlando Pirates midfielder picked the ball up 30 yards out and crashed an effort at goal, with his shot deflecting off Sergio Ramos and striking the crossbar.
After a promising start, the half fizzled out into a scrappy affair with Alonso whipping a low free-kick wide and Bongani Khumalo crashing a header past the near post with the last action of the opening period.
Tokelo Rantie blazed a gilt-edged chance over two minutes into the second period, while Andres Iniesta brought a smart save from Khune, but it was the hosts who took a shock lead in the 56th minute.
Thabo Matlaba burst up the left wing before neatly finding Parker, who dinked over substitute goalkeeper Valdes.
A raft of substitutions seemed to have only further dented Spain's fluidity and there was further cause for concern as Valdes was forced off with 15 minutes to go, as he appeared to injure his knee under no pressure from an opponent.
Pepe Reina became Spain's third keeper of the night, after a lengthy delay as South Africa fumed over the visitors' attempts to use a seventh change of the game - the most permitted for a friendly is six.
Del Bosque could only watch on as his side failed to draw level, with Khune denying Raul Albiol's toe-poked effort in the last minute of stoppage time as Spain slipped to their first loss since July's 3-0 Confederations Cup final defeat to Brazil.
for D. Claasen 46'
for B. Khumalo 46'
for A. Jali 50'
for O. Manyisa 63'
for B. Parker 90+3'
|UAE v Iraq: Rare podium finish on offer|
|Ryan spurred on by Australia´s 2011 heartbreak|
|Montella will not sell Cuadrado cheap|
|Mali, Guinea furious with tie-breaking procedure|
|Luis Enrique defends Neymar´s behaviour|
|Chile 3 USA 2: Gonzalez´s brace extends Americans´ pain|
|Gabi: Referee lacked personality|
|Franjic cleared of serious injury|
|Our progression was deserved - Pochettino|
|Ivory Coast´s tournament starts now - Renard|
|Allegri rejects Juve criticism|
|Atletico´s Arda Turan escapes red card after throwing boot at assistant referee|
|Atletico Madrid 2 Barcelona 3 (agg 2-4): Neymar double secures semi-final spot|
|Parma 0 Juventus 1: Morata late show wins it for visitors|
|Sheffield United 2 Tottenham 2 (agg 2-3): Pochettino books Wembley final|
|Ecuador dismiss Vizuete|
|Championship Preview: Middlesbrough out to continue run, Bournemouth seek response|
|Guinea 1 Mali 1: Lots to decide Group D runners-up|
|Cameroon 0 Ivory Coast 1: Gradel strike sends Renard´s men through|
|Lots to be drawn to decide AFCON qualifiers|
|Eredivisie Preview: De Boer warning for Ajax, leaders PSV host Willem II|
|Bundesliga Preview: Leaders Bayern and Wolfsburg kick off Ruckrunde|
|Howard boost for Everton|
|Ligue 1 Preview: Jardim plays down Monaco title hopes ahead of Lyon showdown|
|Costa charged by FA for alleged Can stamp|
|O´Keefe joins Cardiff|
|Dons teenager Alli in demand|
|Gabriel seals Arsenal switch|
|Wolfsburg v Bayern Munich: Guardiola eyes ´big step´ to Bundesliga title|
|Paris Saint-Germain v Rennes: Montanier seeks another upset in French capital|
|Martinez rules out panic buys|
|Gilardino targets Fiorentina goals|
|Milan agree Bocchetti loan|
|League Two Preview: Cambridge and Luton prepare to renew rivalries|
|Ronaldo hit with two-match ban|
|West Brom complete McManaman deal|
|Sullivan hits back in Sakho row|
|Richards: Cuadrado suited to Premier League|
|Figo to challenge for FIFA presidency|
|Inzaghi out to freshen up struggling Milan|
|Wigan agree a fee for Mckay|
|Carver eyes strong finish|
|Bowen cools talk of Stoke swoop for Sandro and Traore|
|Lazio-bound Morrison lands in Rome|
|Mourinho fined £25k for ´campaign´ claims|
|Mainz bring in Castillo|
|Villa: Lambert will not be sacked|
|Monk hopeful of adding new faces|
|Sainsbury ready to replace Franjic|
|Beckenbauer hopeful of Guardiola stay|
|Mourinho hits back at Costa critics|
|Rodriguez grateful for ´fundamental´ Ronaldo support|
|La Liga Preview: Real want revenge against Socieded|
|No Dallas move for Essien|
|Bale rubbishes United link, Ronaldo rift|
|Sahin in ´good shape´ for Bundesliga resumption|
|Rodgers slams Costa´s stamp collection|
|Under-fire Inzaghi urges patience|
|Rodgers: Courtois saved Chelsea|
|Mashaba wants lessons to be learnt after AFCON exit|
|Mourinho refuses to wade into Costa incidents after Chelsea win|
|Football League Review: Bent double sends Derby second, Rotherham triumph|
|Chelsea 1 Liverpool 0 (aet, agg 2-1): Ivanovic settles action-packed League Cup semi-final|
|Milan 0 Lazio 1: Inzaghi future plunged into further doubt|
|Neymar dreaming of ending Brazil´s home hoodoo|
|South Africa 1 Ghana 2: Late Ayew winner seals qualification|
|Senegal 0 Algeria 2: Mahrez and Bentaleb dump Senegal out|
|Bocchetti poised to join Milan on loan|
|De Rossi suffers calf injury|
|Montano accuses Oldham of double standards after Evans saga|
|Bojan out for the season with ruptured cruciate|
|Cameroon v Ivory Coast: Renard defends Yaya Toure|
|Yanga-Mbiwa makes Roma move permanent|
|Guinea v Mali: Quarter-final berth on offer in Mongomo|
|Thohir: Inter not reliant on European football|
|Bremen land Vestergaard|
|Allegri refuses to rule out Cassano move|
|Mexes handed four-game ban after Lazio dismissal|
|Joyce reveals Valdes´ inspirational team-talk|
|CAF announces AFCON venue switches|
|Alcacer commits future to Valencia|
|Postecoglou calls for Aussie ´energy´|
|Everton confirm Eto´o departure to Sampdoria|
|Pochettino to stick with Vorm despite cup error|
|Barcelona are not favourites against Atletico, says Luis Enrique|
|Allegri wary of Parma backlash in Coppa Italia|
|Zidane urges Real to tie Ancelotti down|
|FIFPro: Transfer system failing football|
|Anderlecht condemn Standard´s Defour banner|
|Australia 2 UAE 0: Socceroos ease into home final|
|Barca overhaul youth system|
|FIFPro demands clubs respect contractual obligations|
|Mahmoud targeting World Cup place with Iraq|
|Fabregas wants Chelsea to show winning mentality|
|Rangers borrow £10m from Ashley´s Sports Direct|
|Lyon face anxious wait over Lacazette|
|Undermanned Lazio recall Perea|
|Ki wants South Korea to prove their superiority|
|Ghana´s Gyan wary of South Africa|
|Mashaba urges South Africa to attack|
|Benitez: Napoli deserved to win|
|Pacos de Ferreira 1 Benfica 0: Leaders fail from the spot|
|Serie A Review: Higuain at the double in controversial Napoli win, Udinese see off Empoli|