This was the result everybody at Arsenal had craved, not least Arsène Wenger and in these fragile times, it was one that the club’s directors could greet with relief. For them, it was exhibit A in the case for continuity.

Arsenal edged back up into fifth place and after the nervy but fortifying home draw against Manchester City on Sunday, this was a powerhouse performance – albeit against a disappointing West Ham United team who have now lost five in a row. Slaven Bilic was the manager who departed with the weight of the world on his shoulders.

It was an evening when Mesut Özil made the difference. At last. The playmaker scored his first goal since 10 December with a curling shot into the far corner and he also laid on the second for Theo Walcott. The substitute, Olivier Giroud, bent a sweet finish beyond Darren Randolph for the third and following the full-time whistle, a group of Arsenal fans could be heard to chant Wenger’s name. It was an occasion for the Wenger In brigade to clear their throats.

Özil has suffered more than any Arsenal player in recent weeks and Wenger said he had been “hit hard” by the Champions League exit against Bayern Munich. “It took some time for him to recover mentally,” the manager added.

Özil was on his game here, probing to unlock a deep-sitting West Ham defence. Crucially he caught a break. Randolph was unnerved by the presence of Alexis Sánchez in front of him after Özil had wafted in his shot and the West Ham goalkeeper could only help it into the net. It was a bad moment for him – as Bilic acknowledged afterwards. “It was a stoppable shot,” he said. Sánchez looked to have been offside but the replays showed he had timed his run to perfection.

It was as if a switch had been flicked in Özil and shortly afterwards he darted on to Sánchez’s back-heeled return pass to pull back the inviting cross for Walcott to score his 19th goal of the season.

West Ham had started well. They were compact and they snapped into tackles. There were even a couple of attacking flickers. Manuel Lanzini sent a dipping free-kick over the crossbar and Mark Noble shot past the far post.

But that was it until the game was beyond them. Emi Martínez, the third-choice Arsenal goalkeeper who played because of injuries to Petr Cech and David Ospina, was not extended until the 75th minute, when he reacted to beat away Lanzini’s fizzing drive. He showed clean handling to save from the substitute, Edmilson Fernandes, in stoppage time.

Wenger could enjoy the clean sheet – particularly, in the absence of the key defender, Laurent Koscielny – and his team’s superior technical quality told. They came to dominate the first-half but could not score. Danny Welbeck missed the clearest chance on 23 minutes when he fluffed a side-on volley following Sánchez’s dinked free-kick.

Walcott felt he ought to have had a penalty in the 18th minute, when Arthur Masuaku checked him with his upper body but there was no decision from Martin Atkinson. The referee would ignore another strong Arsenal penalty appeal on 80 minutes when James Collins went into Nacho Monreal and a blatant one at the very end when Sam Byram caught Monreal.

West Ham put their bodies on the line. Héctor Bellerín had a shot blocked by José Fonte before half-time and Collins threw himself at Mohamed Elneny’s rebound while, after the interval, Collins jumped into a wonderful saving tackle on Özil.

There was niggle. Shkodran Mustafi argued that he was elbowed in the head by Andy Carroll in an aerial challenge while the Arsenal defender was guilty of a reckless lunge at the substitute, Robert Snodgrass, for which he was booked.

Arsenal might have had more in the second-half, with Randolph denying Welbeck at close quarters and Bellerín nudging just wide from Sánchez’s pass. West Ham were left to consider a must-win home game against Swansea City on Saturday. “We are in that fight now [at the bottom],” Bilic said. “It’s not being negative. It’s being realistic.”

For Wenger, there was a moment to reflect on the “world of extremes” in which he lives. “We are always praised too much when it goes well and criticised too much when it doesn’t,” he said. He was not complaining here.