Andy Cole doubled his goals return for the season as he helped to propel Manchester City up to fourth place in the Premiership.
The striker, who celebrated his 34th birthday on Saturday, scored twice as City produced an excellent display to defeat West Ham who were paying their first ever visit to Eastlands.
Cole, who had only scored twice before the visit of the Hammers, opened the scoring with a goal as good as any you will see in the Premiership this season.
And though his second was a scrappy affair, it was just as important as it made certain of the points for City who conceded a stoppage-time goal when Hammers substitute Bobby Zamora netted.
City ought, however, to have won by a far wider margin as they created umpteen chances and in the first half alone were denied three times by goal-line clearances.
City came within a whisker of taking an early lead when Danny Mills' header from a corner by Kiki Musampa beat goalkeeper Roy Carroll but was cleared off the line by Yossi Benayoun.
And after a bright and lively opening, it was no surprise when City took an 18th minute lead with a breathtaking goal.
Darius Vassell made a speedy forward burst and then released Cole with a cheeky back-heel. The striker found the top corner of the net with an exquisite shot which curled beyond the reach of keeper Carroll.
City came agonisingly close to adding a second goal midway through the half when Musampa's cross was flicked past Carroll by Vassell only for Paul Konchesky to save the day for the Hammers with a last-gasp clearance.
Mills, urged by the fans to shoot every time he came forward following his stunning strike against Everton in the last home match, brought a fine save out of Carroll with a ferocious shot from the right side of the pitch.
And in first-half stoppage time City were denied for the third time by a goal-line clearance, Konchesky coming to the rescue again to keep out a goal-bound header from Nedum Onuoha.
The Hammers ought to have drawn level shortly after the restart when Matthew Etherington burst clear from halfway only for goalkeeper David James to spread himself superbly to block the winger's shot.
City then went straight to the other end and almost found the net when Musampa released Vassell only for Carroll this time to thwart him with a brilliant block.
City's persistent pressure finally told when they added a second goal in the 56th minute. Carroll made an excellent stop to keep out Musampa's shot but the ball ran free and a lucky ricochet off Danny Gabbidon fell into the path of Cole who slotted home his second goal of the game from close range.
City might have added a third when Vassell squared the ball to Musampa whose drive flashed into the side-netting.
Cole had a great chance to complete his hat-trick but lifted the ball over the crossbar after Joey Barton had squared the ball and given him a chance which he looked as though he could not miss.
Musampa was unlucky not to score a third goal for City near the end when he broke clear only to be shoved in the back by Hammers defender Christian Dailly.
The referee waved play on but replays showed Dailly ought to have been sent off for a professional foul.
The Hammers pulled a goal back in stoppage time when Benayoun's slide-rule pass released substitute Zamora who sprinted clear and rounded James to slot home his first ever goal in the Premiership.