Watch all the key moments as West Ham bids farewell to the Boleyn Ground in its home finale.
West Ham said farewell to Upton Park in victorious fashion, and it had an impact on the race for England's Champions League places in the process.
West Ham's Diafra Sakho opened the scoring in the 10th minute, and after Manchester United took the lead on two second-half goals by Anthony Martial, headers from Michail Antonio and Winston Reid delivered a 3-2 win in the finale at the Boleyn Ground. West Ham is moving to the Olympic Stadium in London next season.
By winning its final two games, Manchester United would have pipped rival Manchester City to fourth place and the Premier League's final spot in the Champions league. Tuesday's loss, however, gives City the control entering Sunday's season finales. A win or draw at Swansea City would secure fourth place for City and ensure Pep Guardiola does not enter the Premier League with a Europa League-bound side (City's large goal-differential edge would make a draw and a United win acceptable, as both teams would end on 66 points). A City loss and Manchester United win over Bournemouth would put the Red Devils into fourth. A Manchester United loss Sunday would open the door for West Ham to slide into fifth and a Europa League place with a win at Stoke.
Tuesday's Manchester United loss also secured Arsenal's place in the Champions League for next season, guaranteeing the Gunners a top-four finish.
It didn't start out well Tuesday for the Red Devils, who were toothless in the first 45 minutes. Sakho scored from the top of the box after a cross from Manuel Lanzini, neither of which came under a great deal of pressure.
Martial's 51st-minute goal came on a tap-in after a smooth set-up sequence orchestrated by Marcus Rashford and Juan Mata off a goal kick by David de Gea:
Martial then turned in a great individual effort, getting by Winston Reid and beating goalkeeper Darren Randolph from a tight angle to give United its first lead in the 72nd minute:
That lead was short-lived. Michail Antonio headed home from close range after service from Dimitri Payet in the 76th minute, breathing life back into the stands at the Boleyn Ground.
Payet served up another assist four minutes later, sending in a free kick that Reid headed home. De Gea got a hand onto the New Zealand international's header, but he couldn't keep it out of the net, giving West Ham a 3-2 edge and three points in its emotional farewell to its home park.
The match was delayed by 45 minutes after Manchester United's team bus was blocked and attacked by West Ham fans in the streets of London.