Joe Ralls' penalty miss proved costly for Cardiff City as Lucas Perez scored twice to help West Ham to a 3-1 Premier League win at London Stadium.
Having replaced the injured Marko Arnautovic late in the first half, Perez followed up his first Premier League goal since January 2017 with a second just five minutes later to put the game beyond Cardiff.
Things would have been different, however, had Ralls converted from 12 yards in the 35th minute, with Lukasz Fabianski pulling off a comfortable save from the midfielder's tame strike.
And although the loss of Arnautovic seemed to have derailed West Ham's chances, replacement Perez took centre stage before Michail Antonio wrapped up the points just after the hour, meaning Josh Murphy's late header was no more than a consolation for the visitors.
West Ham's dominant start looked set to be rewarded when Arnautovic burst beyond Cardiff's defence and hammered a low strike past Neil Etheridge, only for Sean Morrison to make a crucial block.
Arnautovic was involved at the other end 10 minutes later, with his clumsy challenge on Junior Hoilett giving referee Graham Scott little choice but to award Cardiff a penalty, but Fabianski got down to his left to keep out Ralls' effort.
Arnautovic's hopes of atoning for his error were cut short as he was forced off with a hamstring issue prior to half-time, and Perez made his mark four minutes after the restart, prodding in from close range.
Perez swiftly doubled his tally with a cool finish through Etheridge's legs, with Antonio's header from Robert Snodgrass' corner completing West Ham's 12-minute burst.
Superb saves from Etheridge prevented Angelo Ogbonna and Grady Diangana adding further gloss, and Murphy had the final say when he headed home following a goalmouth scramble in stoppage time.
700 - Lucas Perez has scored his first Premier League goal since January 2017 for Arsenal against Bournemouth, 700 days ago. Interval. December 4, 2018
Get the best features, fun and footballing frolics straight to your inbox every week.
Thank you for signing up to Four Four Two. You will receive a verification email shortly.
There was a problem. Please refresh the page and try again.