Newcastle 3 West Ham 1:Mark Viduka announced his arrival on Tyneside with a first-half double as Newcastle saw off West Ham in a tight encounter.
The Australian got his side off to the perfect start with a second-minute bullet header, and then converted Charles N'Zogbia's cross four minutes before half-time.
In the meantime, Dean Ashton had dragged the visitors back into it with his second goal in as many games since his return from injury, and the Hammers could count themselves unfortunate to go in behind at the break after pinning their hosts back for long periods.
Keeper Steve Harper had to produce excellent one-handed saves to deny first Mark Noble and then former team-mate Lee Bowyer, but the Magpies dominated the second half and were rewarded when N'Zogbia slotted home their third goal after 76 minutes.
In an intensely uncomfortable opening 45 minutes, David Rozehnal and Claudio Cacapa, the latest recruits in the seemingly endless quest to stem the tide of goals which has blighted Newcastle for so long, were given the sternest of examinations by Carlton Cole and Ashton.
It was no surprise when the pair combined on 32 minutes to beat Harper, Cole climbing well to flick on Lucas Neill's long throw for Ashton to fire into the bottom corner.
The goal came as the visitors recovered from a disastrous start which had seen Viduka power home a second-minute header from N'Zogbia's near-post cross, and for much of the half, they were the better side.
Allardyce's men lacked width on the right with Alan Smith sitting in-field and Habib Beye getting forward from full-back only fleetingly.
That left Viduka and Michael Owen isolated, and the Hammers prospered with Noble forcing a fine one-handed save from Harper.
Owen, whose fitness has been the subject of an intense debate all week, was a largely peripheral figure, although he almost opened the door for Viduka once again six minutes before the break after running on to Nicky Butt's ball over the top.
The striker looked up before sending in an inviting cross, and it took a good block by Anton Ferdinand to keep out the Australian's header.
However, there was nothing Ferdinand, or anyone else for that matter, could do to deny Viduka four minutes before the break as he provided further evidence of the wisdom of Allardyce's summer swoop for him.
Once again, it was N'Zogbia who created the opening, bursting past former Magpie Bowyer from Rozehnal's clearance before crossing to the far post for the former Middlesbrough front man to bundle home his second goal of the game and his third in a black and white shirt.
N'Zogbia wasted a 47th-minute free-kick in a promising position after Owen had shown a rare burst of pace to round George McCartney, but was felled in the process.
That proved to be Owen's last contribution of any note and he was replaced by Obafemi Martins four minutes later with the England international worryingly heading straight down the tunnel.
Rozehnal almost caught keeper Robert Green on his heels with a left-foot drive from distance on 53 minutes, and Butt tested the keeper with an equally well-struck effort two minutes later.
But referee Mike Riley had to stop the game two minutes later after Noble reacted furiously to a robust challenge by Nicky Butt.
Harper saved well from Ashton's 64th-minute free-kick, which bounced dangerously in front of him, and Ashton flicked a header wide as West Ham rallied, but the home side were defending with greater resilience than they had before the break.
However, Harper had to be at his best once again in the 72nd minute when Bowyer latched on to Rozehnal's weak header and forced a fine save low to the keeper's right.
But N'Zogbia made sure of the points with 14 minutes remaining when he fed Martins on the left and then met his cross to make it 3-1, and the Nigerian should have added his name to the scoresheet three minutes from time, but fired wide after rounding Green.