Leicester City's nine-year stay in the Premier League came to an end as they were relegated in agonising fashion despite beating West Ham on the final day of the season.
The Foxes' fate was out of their hands heading into the last round of fixtures, and Everton's 1-0 victory over Bournemouth meant the 2015-16 winners slipped into the Championship by two points.
While Toffees fans were in ecstasy at Goodison Park, Leicester supporters at the King Power were left to rue a miserable campaign in which they won only nine league matches.
Knowing they needed a win to have any chance of staying up, Leicester went close early on when Kelechi Iheanacho exchanged passes with James Maddison before clipping the crossbar with a vicious, curling effort.
The hosts did break the deadlock through Harvey Barnes' cool finish from Iheanacho's pass to lead at half-time, and at that stage they were staying up on goal difference.
Jonny Evans almost headed into his own net in a nerve-jangling second half, but the stadium was silenced when word filtered through about Everton scoring.
Said Benrahma struck a delightful curling effort against the post for the visitors, before Wout Faes headed in Leicester's second goal.
Pablo Fornals pulled a goal back by stabbing in via the post as the Hammers finished 14th, six points clear of the relegation zone.
Champions League to Championship
Leicester's game finished before Everton's, which meant the Foxes players had to wait on the pitch for confirmation to come through that they were relegated.
Some huddled around defender Victor Kristiansen's phone, but any glimmer of hope was extinguished when the full-time whistle blew at Goodison.
Many of the crowd jeered, but some did afford their players a generous ovation when they applauded the fans before heading down the tunnel and out of the top flight.
Leicester have been the architects of their own downfall, ending a wretched season with just three wins from their final 17 games and keeping just one clean sheet since November.
Dean Smith's mandate when he was appointed in April was to preserve the status of a side that were shock champions only seven years ago, but nine points from his eight games in charge was simply not enough.
And that means relegation to the Championship just six years after they reached the Champions League quarter-finals.
Barnes' delightful finish and a 1-0 half-time lead gave the Foxes optimism they may just stay alive.
But after Everton took the lead through Abdoulaye Doucoure's brilliant strike, Faes' goal mattered little as Bournemouth could not find a way through.
Leicester supporters did break out into cheers on a number of occasions as news spread of a Cherries 'equaliser' - but each time it was a false dawn.
A summer of upheaval follows for the Foxes, with Maddison and Barnes the most sellable assets, and seven players and manager Smith out of contract.
Hammers looking to European final
West Ham supporters were in fine voice throughout the game, knowing Premier League football was secure for another year, and they have a European final to look forward to.
As news of the scoreline from Goodison came through, they taunted the home crowd with chants of 'You're going down'.
Their team were second best for much of the contest, with Fornals netting a consolation and skipper Declan Rice possibly featuring in his last league game for the club.
This was their 20th league defeat of the season, but their focus was already on Prague, where they face Italian side Fiorentina in the Europa Conference League final on 7 June.
Victory would give them their first major trophy since they lifted the 1980 FA Cup.
Player of the match
BarnesHarvey Barnes
Leicester City
Squad number7Player nameBarnes
Squad number10Player nameMaddison
Squad number14Player nameIheanacho
Squad number8Player nameTielemans
Squad number6Player nameEvans
Squad number27Player nameCastagne
Squad number31Player nameIversen
Squad number3Player nameFaes
Squad number22Player nameDewsbury-Hall
Squad number42Player nameSoumaré
Squad number33Player nameThomas
Squad number24Player nameMendy
Squad number9Player nameVardy
Squad number21Player nameRicardo Pereira
West Ham United
Squad number10Player nameLanzini
Squad number20Player nameBowen
Squad number41Player nameRice
Squad number8Player nameFornals
Squad number11Player nameLucas Paquetá
Squad number33Player nameEmerson
Squad number22Player nameBenrahma
Squad number1Player nameFabianski
Squad number5Player nameCoufal
Squad number9Player nameAntonio
Squad number27Player nameAguerd
Squad number3Player nameCresswell
Squad number14Player nameCornet
Squad number12Player nameDownes
Squad number24Player nameKehrer
Squad number18Player nameIngs
Line-ups
Leicester
Formation 4-2-3-1
31Iversen
27Castagne3Faes6Evans33Thomas
42Soumaré22Dewsbury-Hall
10Maddison8Tielemans7Barnes
14Iheanacho
31Iversen27CastagneSubstituted forRicardo Pereiraat 90+1'minutes3Faes6EvansBooked at 66mins33Thomas42Soumaré22Dewsbury-HallSubstituted forMendyat 71'minutes10Maddison8Tielemans7Barnes14IheanachoSubstituted forVardyat 77'minutesSubstitutes
9Vardy12Smithies15Souttar18Amartey20Daka21Ricardo Pereira24Mendy26Praet37TetêWest Ham
Formation 4-2-3-1
1Fabianski
5Coufal24Kehrer27Aguerd3Cresswell
41Rice12Downes
8Fornals11Lucas Paquetá22Benrahma
9Antonio
1Fabianski5Coufal24Kehrer27Aguerd3CresswellSubstituted forEmersonat 71'minutes41Rice12DownesSubstituted forLanziniat 86'minutes8Fornals11Lucas PaquetáSubstituted forCornetat 71'minutes22BenrahmaSubstituted forBowenat 62'minutes9AntonioSubstituted forIngsat 62'minutesBooked at 67minsSubstitutes
4Zouma10Lanzini13Aréola14Cornet18Ings20Bowen21Ogbonna28Soucek33EmersonLive Text
Match ends, Leicester City 2, West Ham United 1.
Second Half ends, Leicester City 2, West Ham United 1.
Offside, West Ham United. Thilo Kehrer tries a through ball, but Maxwel Cornet is caught offside.
Attempt blocked. Emerson (West Ham United) left footed shot from the left side of the box is blocked. Assisted by Pablo Fornals.
Attempt missed. Pablo Fornals (West Ham United) left footed shot from the centre of the box is too high. Assisted by Danny Ings.
Substitution, Leicester City. Ricardo Pereira replaces Timothy Castagne.
Offside, West Ham United. Declan Rice tries a through ball, but Maxwel Cornet is caught offside.
Delay over. They are ready to continue.
Delay in match because of an injury James Maddison (Leicester City).
Corner, West Ham United. Conceded by Wout Faes.
Substitution, West Ham United. Manuel Lanzini replaces Flynn Downes.
Foul by Timothy Castagne (Leicester City).
Emerson (West Ham United) wins a free kick on the left wing.
Attempt missed. Maxwel Cornet (West Ham United) left footed shot from the centre of the box is too high. Assisted by Emerson with a cross.
James Maddison (Leicester City) wins a free kick on the right wing.
Foul by Declan Rice (West Ham United).
Goal! Leicester City 2, West Ham United 1. Pablo Fornals (West Ham United) right footed shot from the left side of the box to the bottom left corner. Assisted by Danny Ings.
Corner, Leicester City. Conceded by Emerson.
Substitution, Leicester City. Jamie Vardy replaces Kelechi Iheanacho.
Corner, Leicester City. Conceded by Nayef Aguerd.
Our coverage of your Premier League club is bigger and better than ever before - here's everything you need to know to make sure you never miss a moment