Arsenal missed the chance to go top of the Premier League table on Tuesday night as Everton came from behind to win 2-1 at Goodison Park.
Ashley Williams' 86th-minute header completed the comeback for the hosts after Seamus Coleman (44) had cancelled out Alexis Sanchez's deflected free-kick (20).
Phil Jagielka was sent off in the closing stages for a second yellow card - ruling him out of the Merseyside derby on Monday Night Football - before Arsenal twice saw efforts cleared off the line in stoppage time, denying the visitors a dramatic equaliser.
Victory for Arsenal would have sent them above league leaders Chelsea, who travel to Sunderland on Wednesday, but defeat means they remain second, while Everton climb to seventh thanks to their first win in six league matches.
Ronald Koeman made four changes from the defeat to Watford, recalling Ross Barkley to the starting lineup, but the hosts were sluggish in the early stages and fell behind on 20 minutes.
Jagielka fouled Francis Coquelin on the edge of the box, and Sanchez's set-piece ricocheted off the unfortunate Williams and past Maarten Stekelenburg.
With Enner Valencia and Aaron Lennon a growing influence down Everton's flanks, Koeman's side improved as the half wore on and grabbed their equaliser just before the break through Coleman.
The Ireland international was left unmarked by a static Arsenal defence and glanced home Leighton Baines' cross from close range.
Mesut Ozil squandered a golden opportunity to put his side back in front shortly after half-time, firing over from Sanchez's cut-back.
Olivier Giroud and Alex Iwobi were introduced for Arsenal while Koeman brought on Kevin Mirallas and teenager Dominic Calvert-Lewin for his Premier League debut as both sides went in search of a winner.
It came four minutes from time as Williams rose highest from a Barkley corner to head home, setting the stage for a frantic finale.
Jagielka, who had been booked when conceding the free-kick which led to Arsenal's opener, was dismissed by referee Mark Clattenburg for pulling down substitute Lucas Perez.
And with goalkeeper Petr Cech forward for the resulting free-kick, the Gunners went close to snatching a last-gasp equaliser.
Everton failed to clear their lines and with Stekelenburg out of position, Nacho Monreal saw an initial effort blocked before Baines denied Iwobi's goal-bound strike with a stunning block on the line.
Arsenal appealed for a spot-kick as Sanchez then went to ground under the challenge of Mirallas, but the hosts played on leaving Cech stranded, only for Lukaku and Barkley to hesitate with the goal gaping.
It did not matter in the end as Everton held on for the win, condemning Arsenal to their first league defeat on a Tuesday since 2006, with a trip to face Man City up next for Wenger's side, live on Sky Sports.
Player ratings
Everton: Stekelenburg (6), Coleman (8), Jagielka (6), Williams (7), Baines (8), Gueye (7), McCarthy (6), Lennon (6), Barkley (6), Valencia (7), Lukaku (7)
Subs used: Mirallas (6), Calvert-Lewin (6), Funes Mori (6)
Arsenal: Cech (6), Bellerin (6), Gabriel (6), Koscielny (7), Monreal (7), Xhaka (7), Coquelin (6), Ozil (6), Walcott (6), Oxlade-Chamberlain (6), Sanchez (6)
Subs used: Iwobi (6), Giroud (6), Perez (6)
Man of the match: Leighton Baines