Alexandre Lacazette stepped off the bench to boost Arsenal's Champions League qualifying hopes with a VAR assisted winner in a 1-0 victory over West Ham.
The Frenchman fired in from Mesut Ozil's headed cross (78) and, after a long VAR check, the initial offside flag on Ozil was overruled to put Arsenal on course for their third straight Premier League win, which moves them to within five points of fourth place.
It was a tough blow for David Moyes' battling West Ham, who had hit the woodwork in the opening moments through Jarrod Bowen and seen Michail Antonio spurn a glorious close-range chance before forcing a superb stop from Bernd Leno in the second half.
But Gunners manager Mikel Arteta will feel entitled to this valuable victory over his former Everton boss after Arsenal had two penalty appeals denied by VAR and hit the bar themselves through Sokratis in the first half.
They are now closing in on fourth-placed Chelsea, while West Ham - who have lost six away games on the spin - remain out of the relegation zone on goal difference alone.
How Arsenal won the London derby...
West Ham, who had won just two of their previous 23 Premier League trips to Arsenal, came into this match on the back of a hugely important home win over Southampton and they showed their re-found confidence throughout an encouraging first half.
They were almost ahead after just two minutes when Leno allowed Jarrod Bowen's shot from distance to burst through his hands and onto the post, before Antonio then failed to make the most of a West Ham counter-attack when he misplaced a pass to Sebastien Haller in the area.
With Shkodran Mustafi out injured, Pablo Mari made his Premier League debut for Arsenal. Bukayo Saka and Sokratis also came into the side.
West Ham were unchanged after their win over Southampton last time out.
Arsenal - unbeaten in their previous seven Premier League games - had an early sight of goal themselves with a shot over the bar from Granit Xhaka and then also clipped the woodwork when Sokratis headed Pierre-Emerick Aubameyang's cross onto the frame of Lukasz Fabianski's goal.
Chances continued to come at both ends, with Nicolas Pepe impressing with several wonderful dribbles past the West Ham defence, but it was the visitors who went in having missed the best opening - Antonio somehow hooking Issa Diop's knockdown wide from inside the six-yard box.
Arsenal then had strong penalty appeals waved away in first-half stoppage time when Jeremy Ngakia appeared to clip Eddie Nketiah but VAR backed Martin Atkinson's decision to allow play to go on.
Arsenal: Leno (8), Sokratis (6), Mari (6), Luiz (7), Saka (7), Xhaka (7), Ceballos (9), Ozil (7), Pepe (7), Aubameyang (7), Nketiah (6).
Subs: Lacazette (8), Nelson (N/A), Bellerin (N/A)
West Ham: Fabianski (8), Ngakia (6), Ogbonna (7), Diop (7), Cresswell (6), Noble (6), Rice (8), Fornals (7), Bowen (8), Antonio (7), Haller (6)
Subs: Soucek (N/A), Anderson (N/A), Snodgrass (N/A)
Man of the match: Dani Ceballos (Arsenal)
The hosts came out strongly after the break with the impressive Bukayo Saka playing in Nketiah, who forced Fabianski into a point-blank block, but Leno then out-did his opposite number with a superb reaction stop to palm away Antonio's free header at the other end.
Leno was worked again on 66 minutes, this time by Bowen, who had burst through the midfield, and VAR was back in action seconds later at the other end when sub Lacazette appeared to be pulled down by Diop - but once again, VAR opted not to change the on-field call of no penalty.
The biggest VAR drama was to follow though, with the officials in Stockley Park eventually overruling the on-field decision to flag Ozil offside when he teed up Lacazette for the winner 12 minutes from time. After a long delay the Arsenal players and supporters erupted in celebration when ref Atkinson signalled the decision had been changed.
Arsenal held on during a frantic finale and are now eyeing an unlikely place in Europe's elite club competition next season, while West Ham continue to look over their shoulder at the drop zone.
What the managers said...
Arsenal manager Mikel Arteta: "We had the moments of luck we needed but as well it was because we had some really good individual performances at the back, sometimes to clear the ball, sometimes to make the save. I'm really happy with the result because big teams find a way, when they don't have the best day - which is obvious, it wasn't our best day in terms of performance - they find a way to win it.
"You can build from there and you can learn and you can take the positives and the negatives in a much better way. The unity, the solidarity the players are showing, at the end it pays the price. It didn't pay the price a few days ago when played Olympiakos here but it did today."
West Ham manager David Moyes: "We didn't deserve to lose it. In recent weeks we've made mistakes defensively which have cost us a goal. Today I felt as if the mistakes came when we didn't take the chances. Apart from that I thought the players did a great job, played very well, made several good chances but we couldn't convert them. You couldn't fault the players for attitude."
Opta stats - Arsenal now eight unbeaten in Premier League
- Arsenal are unbeaten in eight Premier League games (W4 D4), the longest current run in the competition.
- West Ham have lost each of their last six Premier League away games, their longest such run on the road since a run of eight between August-December 2006 (8).
- Arsenal have kept three clean sheets in their last four Premier League games, as many as they had in their previous 23 in the competition.
- Since the start of last season, Arsenal have scored 16 Premier League goals via substitutes, more than any other side in the competition. Alexandre Lacazette has scored four of these - no other player has scored more.
- All seven of Alexandre Lacazette's Premier League goals for Arsenal this season have been scored at the Emirates, the highest 100% home scoring record in the division this term.
- West Ham manager David Moyes has never won away against Arsenal in 16 attempts (D4 L12) - it's the most a manager has faced a side away from home without ever winning in the competition's history.
Live Premier League
Arsenal now travel to Manchester City on Wednesday for a Premier League clash live on Sky Sports, while West Ham are next in action next Sunday against Wolves - another game you can watch on Sky Sports.