After the heady celebrations of reaching their first FA Cup semi-final in 15 years, West Ham needed a match of this nature to sharpen their senses. That it should end with three points courtesy of Nigel Reo-Coker's stoppage-time winning goal came as an unexpected bonus.

Wigan may not be in the sort of form that enabled them to win 2-0 at Upton Park in December, but after restoring their equilibrium with two straight wins they had the taste for a third. They looked on the way to achieving it when Lee McCulloch gave them a first-half lead. It would have been bigger but for a number of saves by the visitors' goalkeeper, Shaka Hislop.

At that point, West Ham looked as if the drama of their quarter-final win over Manchester City was still on their minds. But after a few well-chosen words from their manager, Alan Pardew, the London side approached the second half with greater commitment, enjoyed a break or two and drew full profit from the game.

"There is no doubt we were suffering a bit of a Cup hangover in the first half, which simply was not good enough," Pardew said. "But in the second half we were brave, deserved a draw and ended up with a win. It has been a fantastic week."

The break was supplied by the Wigan defender Paul Scharner, whose failed attempt to head the ball back to his goalkeeper allowed Marlon Harewood to steal an equaliser seven minutes into the second half. For all that they tried, Wigan could not restore an advantage they probably deserved and suffered for it, the West Ham skipper punishing them at the death.

Wigan should have been in control by half-time but repeatedly found Hislop barring their route to goal. The West Ham goalkeeper made three telling saves, first denying Gary Teale, then keeping out an inswinging Jimmy Bullard free-kick and later palming away a rising drive from McCulloch.

Finally, in first-half stoppage time, came the breakthrough. This time Hislop, perhaps unsighted and certainly out of position, was given no chance as McCulloch spotted a yawning gap inside the left-hand post and let fly, the end result being his fifth goal of the season.

After that, the equaliser came as a surprise, particularly to Mike Pollitt, who had replaced an injured John Filan in the Wigan goal and had barely been involved before Scharner, under pressure from Harewood, tried to head the ball to him. It failed to reach its target and the West Ham striker took full advantage.

Scharner was unlucky not to redeem himself when a brave header from a Bullard corner was stopped on the line by Lionel Scaloni. Five minutes from time, the 37-year-old Hislop again defied the home side with a close-range block from Henri Camara.

Having been kept in the game by one veteran, West Ham won it after the intervention of another. While it was Reo-Coker who supplied the decisive touch, the winning goal came with the Teddy Sheringham stamp of class.

After an exchange of passes on the right had taken him into the Wigan penalty area, the former England striker, who will be 40 next week, typically waited on the ball long enough to see a telling pass, and his release was timed perfectly for Reo-Coker to tuck the ball past Pollitt and complete Pardew's week.