Match ends, Everton 1, West Ham United 0.
Romelu Lukaku came off the bench to score a late winner for Everton against a West Ham side that frustrated the hosts for the majority of the match.
Lukaku, making his first appearance following a month-long absence with an ankle injury, side-footed home Leighton Baines's cross in the last 10 minutes.
The hosts had monopolised possession, with Steven Naismith going close and Steven Pienaar hitting the woodwork.
But stubborn West Ham defending kept the hosts at bay until Lukaku struck.
In a tale of two returning strikers it was Lukaku, rather than West Ham's Andy Carroll, who stole the show and kept alive his side's hopes of qualifying for Europe next season.
Carroll, available again after serving a three-game suspension, was on the pitch for longer, replacing Carlton Cole in the 28th minute, but it was the 20-year-old Belgian who made his presence felt after coming on in the 59th minute.
His strike, only his second league goal in 11 games, not only reduced the gap between Everton and fifth-placed Tottenham to two points but also ended West Ham's five-match unbeaten run in the league.
For possession and territory there was only one team in the match, but for all their dominance and neat passing the hosts were unable to break a West Ham defence that has kept 13 clean sheets this season, the most in the Premier League.
Everton's best chances in the first half fell to Naismith.
The striker was unable to keep two headers on target early on but, midway through the half, forced West Ham goalkeeper Adrian into a reflex save at the near post. That, however, proved to be the home team's only shot on target in the opening 45 minutes.
Gerard Deulofeu also went close, weaving between a number of West Ham defenders before going inches wide with a low shot from the edge of the box.
West Ham occasionally threatened on the counter-attack, and Deulofeu was called into action at the other end of the field to prevent Matt Taylor running through on goal.
But even after the introduction of Carroll, the visitors were unable to muster a shot on target.
If the first half was a damp squib then at least Pienaar ensured the second half started with a bang, hitting the woodwork with a low shot across goal. The follow-up fell kindly for Deulofeu, but Adrian easily gathered the Spaniard's mis-hit half-volley.
Although this match would suggest otherwise, scoring has not been a problem for West Ham of late, with the Hammers hitting the net at least twice in each of their past four league matches.
A palm-stinging save from Tim Howard kept out Carroll's ferocious first-time strike and, moments later, Kevin Nolan was inches wide with a cleverly-worked curling effort - but that was as good as it got for Sam Allardyce's side.
It was no surprise that Roberto Martinez turned to Lukaku for inspiration, and the club's top scorer made the most of his opportunity.
The Belgian, on loan from Chelsea, could have added a second, but shot high with a first-time strike on the turn.
Everton manager Roberto Martinez: "Romelu is someone we have missed for a long time and it was a clinical touch.
"He had a bit of a chest infection and I knew he would be more effective finishing the game rather than starting.
"West Ham had an accumulation of bodies behind the ball, but the last few minutes become harder to defend with Rom with his freshness and power."
West Ham boss Sam Allardyce: "Unfortunately, it wasn't quite good enough in the end.
"Our chances in the final third we should have done a lot better with and those wasted moments could have been the turning point for us.
"We never caused Everton too many problems because of our final ball and our final pass - they didn't put enough fear into their defenders."
- 3BainesBooked at 90mins
- 10DeulofeuSubstituted forMcGeadyat 73'minutes
- 14NaismithSubstituted forBarkleyat 85'minutes
- 21OsmanSubstituted forLukakuat 59'minutes
- 20DemelSubstituted forReidat 80'minutes
- 5TomkinsBooked at 30mins
- 7JarvisSubstituted forDiaméat 66'minutes
- 24ColeSubstituted forCarrollat 29'minutes
- Jonathan Moss
- Shots on Target
Second Half ends, Everton 1, West Ham United 0.
Corner, Everton. Conceded by James Collins.
Attempt missed. Romelu Lukaku (Everton) right footed shot from outside the box is high and wide to the right. Assisted by Leighton Baines.
Leighton Baines (Everton) is shown the yellow card for a bad foul.
Foul by Leighton Baines (Everton).
Andy Carroll (West Ham United) wins a free kick on the right wing.
Sylvain Distin (Everton) wins a free kick in the defensive half.
Foul by Kevin Nolan (West Ham United).
Attempt missed. Ross Barkley (Everton) left footed shot from outside the box misses to the left. Assisted by Gareth Barry.
Leighton Baines (Everton) wins a free kick in the attacking half.
Foul by Kevin Nolan (West Ham United).
Corner, Everton. Conceded by Winston Reid.
Corner, Everton. Conceded by George McCartney.
Substitution, Everton. Ross Barkley replaces Steven Naismith.
Attempt missed. Romelu Lukaku (Everton) left footed shot from the left side of the box is too high. Assisted by Gareth Barry.
Goal! Everton 1, West Ham United 0. Romelu Lukaku (Everton) left footed shot from the centre of the box to the centre of the goal. Assisted by Leighton Baines with a cross.
Substitution, West Ham United. Winston Reid replaces Guy Demel.
Foul by Gareth Barry (Everton).
Andy Carroll (West Ham United) wins a free kick in the attacking half.