England looked like ending a dismal year with a glimmer of hope as a first-half penalty from Adam Lallana and Jamie Vardy's header after the break gave them a thoroughly deserved two-goal lead.
Yet the comeback began with the home fans already heading for the exits as Iago Aspas cut into the area and thumped the ball into the top corner beginning a nervy retreat from England deep into their own territory.
Isco then stunned the Wembley crowd by hitting the ball through substitute keeper Tom Heaton's legs from a tight angle to deprive England boss Gareth Southgate of a major scalp to end his four-game spell in interim charge.
Despite a disappointing end to England's evening, Southgate remains well-placed to take the England job on a permanent basis and the Football Association may feel an otherwise incisive attacking display against one of the world's big hitters has greased the wheels sufficiently for his appointment.
Injured Rooney out of Spain friendly
The 46-year-old has now won two and drawn two of his four games in charge but has steered England through a period of turmoil after Sam Allardyce was forced out 67 days into the job following a newspaper sting and Roy Hodgson quit after a dismal Euro 2016.
"I have loved doing it," he told ITV when asked if he wanted the job. "But it's not my decision, I think we are proud of what we have done with the team. We were asked to take over a situation in a temporary measure and tonight's performance really was very special."
England opened the scoring after nine minutes when Lallana's inch-perfect pass found Vardy running in behind the Spain defence. While the Leicester striker's first touch was far from perfect, he managed to knock the ball around advancing Spain keeper Pepe Reina, who took the forward's legs away to concede a penalty that Lallana thumped high into the net.
Rooney to make England return against Scotland
The Liverpool playmaker has scored in each of his last three games for England, having failed to find the net in his previous 26, but his evening was curtailed midway through the first half when he was forced off through injury.
In his absence, England's threat initially dropped, yet they doubled the lead two minutes into the second half as Vardy ended a 14-game goal drought for club and country with a diving header at the far post from Jordan Henderson's cross.
It could have got better for England but substitute Theo Walcott forced Reina to parry a sharp effort and Henderson scuffed the rebound wide, before former Liverpool forward Aspas cut into the England box to thump the ball into the top corner. That sent jitters through the entire England side, which Isco exploited in the dying seconds.
COMMENTS
Comments are moderated and generally will be posted if they are on-topic and not abusive.
For more information, please see our Comments FAQ