By Phil McNulty
Chief football writer, at the DW Stadium
West Ham United were relegated to the Championship as Wigan Athletic staged a dramatic recovery from two goals down to keep their hopes of Premier League survival alive with victory at the DW Stadium.
Avram Grant's strugglers knew only three points would give them any hope of avoiding the drop after a six-year stay in the top flight - and even then they were relying on Fulham beating Birmingham City.
Wigan, who were at one time rooted to the foot of the table by results around them on an afternoon of drama and tension, then embarked on a stunning comeback that overturned West Ham's advantage and left boss Roberto Martinez harbouring hopes of an escape when they travel to Stoke City next Sunday.
Grant speaks of 'worst day in football life'
Charles N'Zogbia launched the recovery with a free-kick just before the hour and substitute Conor Sammon put Wigan level, and left West Ham staring at the drop, with an equaliser 11 minutes later.
And in a frantic finale that saw both sides trade blows in an attempt to score the goal that could shape their future, Ben Watson hit the post for Wigan before West Ham keeper Robert Green let N'Zogbia's tame shot slip through his grasp for the winner seconds before the end of four minutes of stoppage time.
It was the moment that sealed West Ham's fate - and that of manager Grant, as the club confirmed they had parted company with the Israeli shortly after the final whistle.
That sad end was the final act following a match which saw a first half of optimism and hope for the Hammers transformed into a second period of abject misery.
West Ham's fans aimed a tirade of abuse in Grant's direction as he stood alone on the touchline as their Premier League life drained away, making their feelings abundantly clear about his performance this season.
And West Ham's East End rivals did not miss the target either as, just as Sammon levelled for Wigan, a light aircraft circled the DW Stadium several times trailing the banner: "Avram Grant: Millwall Legend."
West Ham's co-owners David Sullivan and David Gold, in attendance, now face the prospect of losing top players like Footballer of the Year Scott Parker and England keeper Green as they attempt to regain Premier League status before they make their move from Upton Park into the Olympic Stadium.
Parker could only make the bench as he continued his recovery from an Achilles tendon problem - but his influence was barely missed in the opening stages as West Ham took a grip on this vital game.
Wigan actually made the more positive start but the passing approach preached by Martinez was undermined by shambolic defending that was fully exploited by a grateful West Ham.
West Ham struck the vital first blow after 12 minutes when Thomas Hitzlsperger's angled cross was met by Ba's glancing header that left Wigan goalkeeper Ali Al Habsi with no chance for the striker's sixth goal since his arrival from Bundesliga side Hoffenheim.
And he was on target again as Wigan were once more found wanting in the aerial exchanges as Ba touched home James Tomkins' header from almost on the goalline after the defender rose to meet Hitzlsperger's free-kick.
West Ham's fans had opened the game with gallows humour, taunting their Wigan counterparts with "You're going down with the West Ham" and "Whatever will be will be - we're going to Coventry."
Suddenly they were dreaming of an unlikely survival and almost extended their lead just after the half-hour when Watson scrambled back just in time to clear Frederic Piquionne's shot off the line.
Martinez revels in Wigan comeback
Wigan needed to mount a swift response and West Ham were indebted to goalkeeper Green for ensuring they reached the interval with their two-goal advantage intact. He showed sharp reactions to save Hugo Rodallega's overhead kick and then blocked Mohamed Diame's shot.
He was fortunate in the closing moments of the half, saving more by accident than design as Rodellega stooped to send in a header from only six yards out.
Martinez made a double change at half-time, sending on Sammon and Victor Moses for Tom Cleverley and James McCarthy - but it was the inspirational figure of the gifted N'Zogbia who handed them a lifeline after 57 minutes.
He was fouled by Tomkins but recovered to send a stunning free-kick high past Green into the top corner to give Wigan hope that they might yet salvage something from the wreckage of the first half.
Grant was in deep discussion with coach Wally Downes about his next move, but the decision was eventually enforced as Jonathan Spector limped off and was replaced by Parker, who was given a standing ovation from West Ham's supporters.
As the game opened up Ba was presented with the chance to make it a treble but his finish was tame as he raced clear and Al Habsi collected comfortably.
It was to prove an expensive miss as Wigan drew level after 68 minutes to complete their recovery and leave West Ham on the brink of relegation, Sammon controlling coolly in the area before sliding a low finish away from Green.
West Ham were now in dire straits and Grant reacted by sending on Carlton Cole for Piquionne in an attempt to rescue the situation with the goal they required. He was soon joined by Robbie Keane as West Ham gambled all their cards on survival.
West Ham relegation a massive blow - Redknapp
And it took a scrambled clearance on the line from Wigan captain Gary Caldwell to keep out Zavon Hines' shot as the action swung dramatically from end to end in spectacular fashion.
West Ham were leaving spaces everywhere as they threw caution to the wind and Watson almost snatched the winner only to see his low shot hit the inside of the post and bounce back into the grateful arms of Green.
Green then plunged bravely at Sammon's feet - but he was guilty of another of the errors that scar his game as Wigan confirmed West Ham's drop back into the Championship with virtually the final kick of the game.
N'Zogbia cut in from the right, and even though his shot lacked power Green allowed it to squirm underneath his body amid scenes of near hysteria inside the DW Stadium.
There was nothing but despair among West Ham's followers behind Green's goal - and seconds later referee Mike Dean blew the final whistle to spark vastly contrasting emotions.
90:00+5:59 The final whistle is blown by the referee.
90:00+4:47 Substitution (Wigan) makes a substitution, with James McArthur coming on for Hugo Rodallega.
90:00+3:45 GOAL - Charles N'Zogbia:Wigan 3 - 2 West Ham Charles N'Zogbia scores a goal from the edge of the penalty area to the bottom left corner of the goal. Wigan 3-2 West Ham.
90:00+2:42 The referee blows for offside against Carlton Cole. Ali Al Habsi takes the indirect free kick.
90:00+1:31 Thomas Hitzlsperger has shot on goal from just outside the penalty box which goes wide of the right-hand upright.
90:00+0:52 Scott Parker takes a shot. Save made by Ali Al Habsi.
89:57 Ben Watson takes a shot.
88:50 Charles N'Zogbia takes a inswinging corner from the right by-line played to the near post, save by Robert Green.
88:17 Corner taken right-footed by Ben Watson, save by Robert Green.
87:15 Long range shot from Zavon Hines misses to the left of the target.
86:24 Demba Ba takes a shot. Save made by Ali Al Habsi.
85:47 Inswinging corner taken by Thomas Hitzlsperger from the right by-line, Antolin Alcaraz manages to make a clearance.
84:46 Unfair challenge on Carlton Cole by Gary Caldwell results in a free kick. Strike on goal comes in from Thomas Hitzlsperger
from the free kick.
83:23 Zavon Hines takes a shot. Maynor Figueroa gets a block in.
82:41 Substitution Jack Collison leaves the field to be replaced by Robbie Keane.
82:18 The ball is delivered by Wayne Bridge, Shot by Zavon Hines. Save made by Ali Al Habsi.
81:30 Inswinging corner taken left-footed by Charles N'Zogbia, Robert Green makes a save.
80:52 Inswinging corner taken by Charles N'Zogbia, Carlton Cole makes a clearance.
80:09 Shot from close range by Victor Moses misses to the left of the goal.
79:17 Ben Watson restarts play with the free kick.
79:17 Booking Caution for Scott Parker.
79:14 Free kick awarded for a foul by Scott Parker on Hugo Rodallega.
78:19 Corner from the left by-line taken by Thomas Hitzlsperger, clearance by Emmerson Boyce.
78:06 Demba Ba is ruled offside. Indirect free kick taken by Ali Al Habsi.
77:47 Thomas Hitzlsperger takes a shot. Blocked by Gary Caldwell.
77:21 Robert Green takes the direct free kick.
77:21 Booking Charles N'Zogbia goes into the referee's book for unsporting behaviour.
77:12 Charles N'Zogbia challenges Jordan Spence unfairly and gives away a free kick.
76:47 Corner taken right-footed by Ben Watson, clearance by Carlton Cole.
75:17 Scott Parker concedes a free kick for a foul on Conor Sammon. Charles N'Zogbia has an effort direct from the free kick.
73:48 Substitution Carlton Cole is brought on as a substitute for Frederic Piquionne.
73:08 Corner taken by Thomas Hitzlsperger from the right by-line.
67:29 Assist on the goal came from Ben Watson.
67:29 GOAL - Conor Sammon:Wigan 2 - 2 West Ham Conor Sammon finds the net with a goal from inside the penalty area to the bottom right corner of the goal. Wigan 2-2 West
66:02 Long range shot by Hugo Rodallega goes wide right of the target.
65:38 Demba Ba takes a shot. Ali Al Habsi makes a save.
61:04 Maynor Figueroa concedes a free kick for a foul on Zavon Hines. Thomas Hitzlsperger restarts play with the free kick.
60:00 Substitution (West Ham) makes a substitution, with Scott Parker coming on for Jonathan Spector.
57:10 Victor Moses challenges Demba Ba unfairly and gives away a free kick. Robert Green restarts play with the free kick.
56:18 GOAL - Charles N'Zogbia:Wigan 1 - 2 West Ham Charles N'Zogbia finds the net with a goal direct from the free kick from just outside the penalty box to the top left corner
of the goal. Wigan 1-2 West Ham.
55:09 James Tomkins concedes a free kick for a foul on Charles N'Zogbia.
53:51 Demba Ba has an effort at goal from the edge of the box that misses to the right of the target.
52:30 Free kick awarded for an unfair challenge on Maynor Figueroa by Zavon Hines. Direct free kick taken by Ben Watson.
50:54 Ben Watson produces a right-footed shot from a long way out which goes wide right of the goal.
49:48 Demba Ba is ruled offside. Gary Caldwell restarts play with the free kick.
49:36 Maynor Figueroa delivers the ball, save by Robert Green.
45:01 The second half begins.
45:01 Substitution (Wigan) makes a substitution, with Conor Sammon coming on for Tom Cleverley.
45:01 Substitution James McCarthy leaves the field to be replaced by Victor Moses.
45:00+2:16 The ref blows to end the first period.
44:39 Shot on goal by Tom Cleverley from just inside the area clears the crossbar.
40:42 Shot by Mohamed Diame from just outside the area goes over the net.
38:45 Unfair challenge on Zavon Hines by Ben Watson results in a free kick. Free kick crossed left-footed by Thomas Hitzlsperger,
clearance by Antolin Alcaraz.
37:48 Corner taken by Ben Watson from the left by-line, Hugo Rodallega takes a shot. Save by Robert Green.
37:23 Mohamed Diame takes a shot. Robert Green makes a save.
35:36 Long distance shot from Antolin Alcaraz misses to the left of the target.
35:05 Hugo Rodallega takes a shot from 18 yards. Save by Robert Green.
34:41 Corner taken by Ben Watson, save by Robert Green.
34:04 Charles N'Zogbia takes the inswinging corner, Daniel Gabbidon manages to make a clearance.
32:19 Outswinging corner taken by Thomas Hitzlsperger.
31:55 The referee blows for offside. Thomas Hitzlsperger takes a outswinging corner.
31:54 Frederic Piquionne takes a shot. Save made by Ali Al Habsi.
31:24 Free kick awarded for an unfair challenge on Zavon Hines by Maynor Figueroa. The free kick is delivered left-footed by Jordan
Spence from right channel.
30:20 Inswinging corner taken from the left by-line by Ben Watson.
29:03 Charles N'Zogbia fouled by Frederic Piquionne, the ref awards a free kick. Strike comes in from Charles N'Zogbia from the
28:16 Free kick awarded for a foul by Frederic Piquionne on Charles N'Zogbia. Ben Watson takes the free kick.
25:11 James Tomkins provided the assist for the goal.
25:11 GOAL - Demba Ba:Wigan 0 - 2 West Ham Demba Ba finds the back of the net with a headed goal from inside the six-yard box. Wigan 0-2 West Ham.
24:51 Foul by Ben Watson on Jonathan Spector, free kick awarded. Free kick crossed left-footed by Thomas Hitzlsperger from left
channel, Gary Caldwell manages to make a clearance.
24:31 Mohamed Diame takes a shot. Robert Green makes a comfortable save.
22:16 Jordan Spence gives away a free kick for an unfair challenge on Maynor Figueroa. Ben Watson crosses the ball in from the free
kick, Daniel Gabbidon manages to make a clearance.
22:07 Emmerson Boyce delivers the ball, James Tomkins manages to make a clearance.
20:24 Foul by Frederic Piquionne on Maynor Figueroa, free kick awarded. Maynor Figueroa takes the direct free kick.
14:24 Charles N'Zogbia takes a shot. Save by Robert Green.
12:46 Free kick awarded for a foul by Zavon Hines on Maynor Figueroa. Maynor Figueroa restarts play with the free kick.
11:09 The assist for the goal came from Thomas Hitzlsperger.
11:09 GOAL - Demba Ba:Wigan 0 - 1 West Ham Demba Ba scores a headed goal from inside the six-yard box. Wigan 0-1 West Ham.
10:35 Corner taken by Thomas Hitzlsperger.
10:06 Hugo Rodallega takes a shot. Comfortable save by Robert Green.
9:30 Foul by Thomas Hitzlsperger on James McCarthy, free kick awarded. Gary Caldwell takes the free kick.
6:37 Emmerson Boyce crosses the ball, save made by Robert Green.
3:11 Mohamed Diame has an effort at goal from the edge of the area that misses to the right of the target.
0:54 Ben Watson takes a corner.
0:00 The ref blows the whistle to begin the match.
Live text and data provided by The Press Association.
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.