Ghana suffered a humiliating group-stage exit at the Africa Cup of Nations after the four-time champions were beaten by debutants Comoros.
El Fardou Ben Nabouhane put the islanders ahead early on, and Ghana then went down to 10 men when Andre Ayew was shown a straight red card.
Ahmed Mogni doubled the lead before the Black Stars fought back to make it 2-2.
However, Mogni tapped in his second in the 85th minute to inflict Ghana's first group-stage exit since 2006.
The result in Group C will go down as one of the biggest shocks in Nations Cup history as Comoros scored at the finals for the first time and then went on to record their maiden victory.
Incredibly, the side ranked 132nd in the world now have a chance to reach the knockout stages as one of four best-ranked third-placed sides even though the Coelacanths lost their first two games in Cameroon.
The tiny island nation with just under a million inhabitants - and more famous for itshistory of political coupsthan its football - had only won its first Nations Cup or World Cup qualifier in 2016 at the 20th attempt.
A squad bolstered by members of the diaspora, with many plying their trade in the lower leagues in France, lost just once toachieve a maiden qualificationand Comoros have now beaten one of the continent's giants.
Ghana had put in disjointed displays in their first two games, a 1-0 defeat by Morocco and a niggly 1-1 draw with Gabon, and finish bottom of the group table despite putting in a spirited display following Ayew's 25th-minute sending off.
Their fans in the Roumde Adjia Stadium in Garoua looked stunned at the full-time whistle, being left to contemplate a rollercoaster second half which ended their bid for a first Nations Cup title since 1982.
The Serb led the Black Stars to the Nations Cup final in 2010 and the World Cup quarter-finals the same year, and guided the West Africans through to Africa's play-offs for this year's World Cup.
However, Ghana only won their qualifying group ahead of South Africa on goals scored and are unseeded for the play-off draw - where they will face one of Senegal, Morocco, Tunisia, Algeria and Nigeria for a place in Qatar.
Comoros, meanwhile, celebrated their three points heartily and now await the final round of matches in the remaining three groups to see if their stunning victory can extend their stay at the tournament.
VAR decision leaves Ghana reeling
Ghana had needed a win to have a chance of a spot in the last 16 and made the worst possible start by conceding in the fourth minute.
Ibroihim Youssouf was released down the right before finding Ben Nabouhane in the middle, and the Comoros skipper sent a low left-footed shot into the bottom right-hand corner from the edge of the area.
Kamaldeen Sulemana tested Comoros keeper Salim Ben Boina with two shots from outside the area, the second of which provided another turning point in the contest.
Ben Boina spilled the winger's shot and Ayew went in strongly in an attempt to win the loose ball.
The coming together injured the keeper and the Ghana captain looked surprised to be shown red following a video assistant referee review, with replays showing he went in with studs up and made contact with Ben Boina's upper arm.
The Comoros keeper was injured in the clash and forced off, leading to the introduction of Ali Ahamada, who came into the tournament without a club side.
Black Stars rally but ultimately denied
The islanders made it 2-0 just after the hour mark as Mogni twisted and turned the Ghana defence on the edge of the area before sending a low shot past Jojo Wollacott and into the bottom right-hand corner.
The strike sparked a group celebration down by the corner-flag involving substitutes - but Ghana immediately stirred.
Richmond Boakye looped in a header from a corner and, after Ahamada had clawed away two threatening balls in from Daniel-Kofi Kyereh, Ghana levelled in the 77th minute from another set piece.
Arsenal midfielder Thomas Partey flicked on a corner and Alexander Djiku was on hand to convert from close range to give the Black Stars renewed hopes of going through.
But those dreams were dashed five minutes from time when Bendjaloud Youssouf cut the ball back for Mogni to seal a famous win for Comoros.
Ghana, who appear to lack leaders of the calibre of Asamoah Gyan, the striker who led them to the last eight at the World Cup 12 years ago, now face the challenge of regrouping before March's World Cup play-offs.
Line-ups
Ghana
Formation4-4-2
16Wollacott
2Yiadom18Amartey23Djiku17Baba
22Sulemana5Partey8Kyereh7Issahaku
10A Ayew9J Ayew
16Wollacott
2YiadomBooked at 78minsSubstituted forOwusuat81'minutes
18Amartey
23Djiku
17BabaSubstituted forAddoat45'minutes
22SulemanaSubstituted forBoakyeat60'minutes
5Partey
8Kyereh
7IssahakuSubstituted forPaintsilat60'minutes
10A AyewBooked at 25mins
9J Ayew
Substitutes
1Nurudeen
3Baffour
4Mensah
6Addo
13Boakye
14Mensah
15Paintsil
19Owusu
24Attah
26Mumin
27Quaye
Comoros
Formation4-4-2
1Ben Boina
15Youssouf4Zahary12M'Dahoma22Bakari
7Selemani10M'Changama8Bachirou20Mogni
17Youssouf21Ben Nabouhane
1Ben BoinaSubstituted forAhamadaat26'minutes
15YoussoufSubstituted forAbdullahat90'minutes
4Zahary
12M'Dahoma
22Bakari
7SelemaniBooked at 14mins
10M'Changama
8BachirouSubstituted forAbdouat90'minutes
20MogniSubstituted forYoussoufat90'minutes
17YoussoufSubstituted forMattoirat60'minutes
21Ben Nabouhane
Substitutes
2Abdallah
3Alhadhur
5Ali Mohamed
6Abdou
9M'Changama
11Aboubakari
13Abdullah
14M'Madi
19Youssouf
23Ahamada
24Mattoir
26Mohamed
Referee:
Boubou Traore
Match Stats
Live Text
Match ends, Ghana 2, Comoros 3.
Second Half ends, Ghana 2, Comoros 3.
Attempt missed. Daniel-Kofi Kyereh (Ghana) right footed shot from a difficult angle and long range on the left is too high from a direct free kick.
Joseph Paintsil (Ghana) wins a free kick on the left wing.
Foul by Mohamed Youssouf (Comoros).
Alexander Djiku (Ghana) wins a free kick in the defensive half.
Foul by El Fardou Ben Nabouhane (Comoros).
Thomas Partey (Ghana) wins a free kick in the attacking half.
Foul by Rafidine Abdullah (Comoros).
Jordan Ayew (Ghana) wins a free kick in the attacking half.
This website or its third-party tools use cookies, which are necessary for analytics and its functioning and required to achieve the purposes illustrated in the cookie policy, including the personalization and analysis of ads and content. If you want to learn more or withdraw your consent to all or some of the cookies, please refer to the cookie policy.
By clicking on Accept you are agreeing to the placement of cookies on your device.
Further use of our site shall be considered as consent. You may view our Privacy Policy and Cookie Policy here for more information.
This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.
Strictly Necessary Cookies
Strictly Necessary Cookie should be enabled at all times so that we can save your preferences for cookie settings.
If you disable this cookie, we will not be able to save your preferences. This means that every time you visit this website you will need to enable or disable cookies again.