Manchester United continued their march towards a Champions League spot thanks to Craig Dawson’s own goal.
Ole Gunnar Solskjaer’s side may be finding goals hard to come by in recent weeks – four in their last six games – but are proving stubborn opponents to break down.
Victory made it 13 games unbeaten in all competitions for United, who moved back up above Leicester into second spot, 14 points behind leaders Manchester City, albeit with a game in hand.
They may be too far back to catch local rivals Manchester City, but securing second spot would represent another season of progress for United under Solskjaer, who is in line for a new deal.
Dawson’s second-half own goal put United nine points clear of their fifth-placed opponents and has kept Solskjaer and his players on course for an immediate return to European club football’s premier competition.
United were handed a boost before kick off with Marcus Rashford fit enough start, an ankle injury having forced him to miss the 1-1 draw in midweek with AC Milan.
West Ham boss David Moyes, who endured an ill-fated 11-month spell in charge of United, arrived at Old Trafford having failed to win as an opposing manager in 14 attempts, losing 10 and drawing four.
Moyes was without Jesse Lingard, with four goals in six games for the Hammers, the midfielder ineligible to play under the terms of his loan deal from parent club United.
After a sloppy start from the hosts, they conjured the first real chance, one Rashford should have handled with more competence, in the 25th minute.
Bruno Fernandes funnelled the ball out right to Mason Greenwood, who picked out Rashford with a perfect in-swinging delivery, but the United forward was unable to direct his free header on target.
The opening seemed to galvanise United, who shrugged off their early inertia and began to play with greater freedom and enterprise, with Greenwood inspiring their most effective attacking moments.
Greenwood came close to opening the scoring in the 37th minute, only to be denied by a fine save from Lucsz Fabianski.
Fernandes found Greenwood, who cut inside onto his left foot before unleashing a goalbound shot which Fabianski tipped onto his right-hand post and behind for a corner.
United emerged for the second-half with the same intent, Vladimir Coufal getting a vital touch on a Greenwood cross, with Rashford lurking behind him, ready to turn the ball in.
But United took the lead from the resulting corner in the 54th minute, the delivery from Fernandes headed into his own net by Dawson, who had been impressive up until that point.
United pushed for a second, Fabianski showing superb reactions and agility once again to get down low to his right and palm away a low drive from Fernandes.
When Fabianski was beaten, in the 77th minute by Greenwood, after a counter-attack at breakneck speed, the frame of the goal saved him, the ball thudding off his right-hand post.
United squandered opportunities to add a second goal that would have ensured a calmer end to the game for them, with Dan James using his pace to get into some dangerous positions, only for his final ball to let him down.
West Ham’s lack of any kind of cutting edge up front, allied to United’s defensive solidity, ensured Dawson’s own goal was enough to win the game for the Reds and edge them closer to securing a Champions League spot.