Achraf Hakimi calmly converted a penalty to send Morocco through to the World Cup quarter-finals for the first time with a 3-0 shootout win over former champions Spain after a cagey last-16 clash ended goalless on Tuesday.
Morocco goalkeeper Yassine Bounou saved spot-kicks from Carlos Soler and Sergio Busquets after Pablo Sarabia had hit the post and Spanish-born Hakimi held his nerve to earn his team a quarter-final against either Portugal or Switzerland.
Morocco became only the fourth African nation to reach the last eight of the tournament, 12 years after Ghana did so in South Africa.
After a scrappy match finished deadlocked at 0-0 after extra time with few shots on target, Morocco fed off the raucous support of their red-clad supporters in the shootout as Spain crumbled.
Spain enjoyed more than 75 per cent of possession and completed almost 800 passes but Morocco caused problems for them on the counter-attack and goalkeeper Unai Simon made some good saves.
It was the fourth time Spain have been knocked out of the World Cup on penalties and the second in a row.
Morocco World Cup squad 2022
Goalkeepers: Yassine Bono, Munir, Ahmed Reda Tagnaouti
Defenders: Achraf Hakimi, Noussair Mazraoui, Romain Saiss, Nayef Aguerd, Achraf Dari, Jawad El-Yamiq, Yahia Attiat-Allal, Badr Benoun
Midfielders: Sofyan Amrabat, Selim Amallah, Abdelhamid Sabiri, Azzedine Ounahi, Bilel El Khanouss, Yahya Jabrane
Forwards: Hakim Ziyech, Youssef En-Nesyri, Sofiane Boufal, Zakaria Aboukhlal, Ez Abde, Amine Harit, Ilias Chair, Abderrazak Hamdallah, Walid Cheddira
Who is their best player?
Other than Hakim Ziyech, the team's standout player is undoubtedly Achraf Hakimi, who plays at right back for Paris Saint-Germain. Despite being born in Spain, Hakimi has represented Morocco since under-17 level, before making his full debut in 2016.
Telegraph readers rated Ziyech the best Morocco player in their opening match against Croatia with a rating of 7.5, level with midfielder Sofyan Amrabat.
What are Morocco's results and fixtures?
Morocco face Portugal in the quarter-finals of the World Cup in Qatar. The match will be played at Al Thumama Stadium on Saturday December 10, kick-off at 3pm (GMT).
November 23: Morocco 0 Croatia 0
November 27: Belgium 0 Morocco 2
December 1: Canada 1 Morocco 2
Round of 16
December 6: Morocco 0 Spain 0; Morocco win 3-0 on penalties
What is Morocco's World Cup record?
As an independent nation, Morocco has taken part in five World Cup finals, competing before 1958 as part of France. Their highest finish came in 1986, when they progressed from the group stage to play West Germany in Mexico. They were knocked-out by the eventual finalists 1-0.
Argentina | Australia | Belgium | Brazil | Cameroon | Canada | Costa Rica | Croatia | Denmark | Ecuador | England | France | Germany | Ghana | Iran | Japan | Mexico | Morocco | Netherlands | Poland | Portugal | Qatar | Saudi Arabia | Senegal | Serbia | South Korea | Spain | Switzerland | Tunisia | Uruguay | USA | Wales
Morocco are currently a best price of 40/1 to win the World Cup.