Morocco stunned Spain on penalties to advance to the quarter-finals of the World Cup after a 0-0 draw at the Education City Stadium.
Walid Regragui's side defended spectacularly for 120 minutes, although Spain offered very little cutting edge in the final third, and it was a similar story from the spot for the 2010 champions.
Spain did not score a single penalty in the shootout, as Pablo Sarabia, Carlos Soler and Sergio Busquets all missed before Achraf Hakimi had the audacity to send the Atlas Lions through to the last eight with a Panenka.
Spain boss Luis Enrique made the big call to drop Alvaro Morata - who scored three goals in three group stage games - from the starting lineup, and the decision did not bear fruit early on.
Indeed, La Roja only had one shot in the first half, which came in the 26th minute as Marco Asensio hit the side netting from a tight angle, but the offside flag had to come to Yassine Bounou's rescue only one minute prior.
The Sevilla goalkeeper did not cover himself in glory in possession during the first half, but he did brilliantly to tip Gavi's effort onto the crossbar before the linesman's flag was raised.
© Reuters
The Atlas Lions had their fair share of joy in the final third, although Youssef En-Nesyri was largely anonymous, and Nayef Aguerd headed over the bar from close range in the 42nd minute.
Despite completing 372 passes and enjoying 69% possession, Spain's attacking nous was non-existent in the first half, although Enrique did not make any alterations at the break.
La Roja finally had their first shot on target in the 55th minute, as Asensio played a free kick short to Dani Olmo, who stung the palms of Bounou from a tight angle.
Enrique had finally seen enough and introduced Morata for Asensio in the 63rd minute, but Spain still had no answers to the questions that Morocco's well-drilled defensive unit asked of them.
The introduction of Nico Williams injected some much-needed pace down the right for Spain, but Enrique's side could not fashion any reasonable chances in the dying embers of normal time, barring a 95th-minute Olmo free kick which evaded everyone before being beaten away by Bounou.
Morocco's rearguard remained under the cosh in the first period of extra time but continued to defend valiantly, and they were presented with a gilt-edged chance to take the lead in the 104th minute, but Walid Cheddira fired straight at Simon from close range.
© Reuters
Substitute Sarabia was inches away from sending Spain through to the quarters with the last kick of the game, but his volley at the far post smacked the other side of the woodwork as penalties loomed.
History repeated itself for Sarabia - brought on for the impressive Williams just for the shootout - as he hit the post with Spain's first penalty before Hakim Ziyech blasted his spot kick straight down the middle to put Morocco 2-0 up.
Sarabia's Paris Saint-Germain teammate Soler was next up to the 12-yard spot, but his tame effort was kept out by Bounou, although Badr Benoun's strike was also saved by Unai Simon.
La Roja's reprieve did not last long, though, as Bounou dived to his right to keep out Busquets's effort before Hakimi's delicate chip nestled into the net to send the raucous Moroccan crowd into a frenzy.
Regragui's side will now take on the winners of Portugal's last-16 clash with Switzerland in their quarter-final at the Al Thumama Stadium on Saturday.
No Data Analysis info