After an arid midweek at Old Trafford something told us that it might be followed by a veritable deluge in the East End. And so it proved, goals and near-misses flowing from the heavens as Manchester United reclaimed the summit. Galvanised by the prospect of having their position at the head of Premiership affairs usurped by Liverpool, Sir Alex Ferguson's team twice permitted their hosts, invariably among their most troublesome opposition – it had been 14 weeks since Jermain Defoe's winning goal at Old Trafford prompted Ferguson to concede the championship, prematurely as it transpired – to secure a first-half advantage before equalising by the break. Then, like some prone collosus caught taking a nap, his team grunted, open its eyes, and swatted away the opposition almost contemptuously.

After the interval, Ferguson's men should have cruised to a facile triumph after Paul Scholes and Ole Gunnar Solskjaer had profited from some dubious Hammers' defending. The scintillating David Beckham, scorer of a sublime opener for his side and the creator of Nicky Butt's second, and the marauding Roy Keane taunted the home rearguard mercilessly.

But there is always a doubt about Manchester United's ability to sustain an advantage these days, as Derby County demonstrated a fortnight ago. When the substitute Defoe appeared and scored virtually immediately that frailty was again evident until Beckham tidied things up with a late penalty. "Marvellous, delicate, just beautiful," Ferguson oozed contentment over the England captain's first goal.

When asked if the midfielder's much-debated mid-season R & R had contributed to the kind of performance he produced yesterday, the United manager declared: "No doubt. He's been absolutely magnificent in the last few weeks. That's the David Beckham we all want to see." Ferguson added: "It took us a long while to get going, but it was a marvellous game."

It was, because the Hammers, who rarely produce anything other than their best here in front of a demanding crowd, unnerved the visitors with their forceful play in the first half particularly.

With memories of that less than fiercely competitive goalless draw against Bayern Munich, it was rich entertainment provided by Manchester and their hosts, even if it was not easy on the eye for members of the Defenders' Union.

Paolo Di Canio, who six weeks ago was close to signing for Ferguson, but was prevented up the chain, so to speak, by Dwight Yorke's failure to agree terms with Middlesbrough, decidedly had a point to prove and was in wickedly inventive mood. In the early seconds, the Italian had an effort charged down by Gary Neville which emphasised to the visitors that this would be far from a comfort zone. It was only seven minutes later that Steve Lomas confirmed that impression, the Northern Ireland midfielder dispatching a long-range header from Vladmir Labant's cross, past Fabien Barthez.

Glenn Roeder's men were buoyed by that early breakthrough, but 10 minutes later, Joe Cole, who failed to exude the class that has made him an England contender, attempted a pass which was intercepted by Scholes and released to David Beckham. His sweetly-executed lob caught David James flat-footed. A mere three minutes later, an incisive move found out the visitors again, as the impressive Michael Carrick, returning after four months' absence with injury, found the overlapping Sébastien Schemmel, and the Frenchman's low cross was swept in deftly by his compatriot Frédéric Kanouté. Again Manchester United replied when, from a Beckham free-kick, Butt headed home. And not even a quarter of the game gone.

The second half was almost solely the visitors' domain. Ten minutes after the interval, Solskjaer cut the ball back cleverly from the goal-line, allowing Scholes to pounced from close range and edge his side into the lead for the first time. Then, just after the hour, Solskjaer converted at the second attempt from the most acute angle as James and the home defence failed to block him. United were rampant.

Roeder withdrew Nigel Winterburn 17 minutes from time, and replaced him with Defoe. It fired West Ham with renewed belief. Five minutes later, the move proved to have been an astute one, indeed, when the diminutive striker drove the ball home after excellent work by Kanouté.

But with two minutes remaining, Tomas Repka was adjudged to have fouled Paul Scholes in the area. Beckham duly buried the spot-kick in the centre of James's net. "It was very disappointing to score three at home against a special team who might end up as the best in Europe but not take a point," Roeder, the Hammers' manager, reflected. "But we contributed to our own downfall with some sloppy play."

For Manchester United, it was plentiful compensation for that afternoon of ignominy at Old Trafford back in December when Ferguson was still convinced this season would be his last and United appeared to have yielded the championship. Since then we have learnt never to write off either.