Alexandre Lacazette scored twice in the last 10 minutes as Arsenal left it late to see off West Ham.
Nacho Monreal put the home side but his effort was cancelled out by Marko Arnautovic.
Aaron Ramsey's strike restored their lead late on before Lacazette struck twice in the dying minutes to give Arsene Wenger victory in his first game since announcing he will step down as boss.
Lacazette 7: Led the line ahead of Aubameyang as a rehearsal for Atletico - eventually paid off.
Alexandre Lacazette's late show made the points safe (Image: Getty Images Europe) Hart 7: Made outstanding saves to deny Welbeck and Xhaka but horribly caught out on second goal.
Marko Arnautovic was on target for the Hammers (Image: REUTERS) Kouyate 7: Worked hard in midfield, shielded the West Ham defence to good effect.
Arnautovic 7: His power and pace caused problems, West Ham’s most dangerous and best player.
- Arsenal aiming to give Wenger the perfect send off - MertesackerAOL UK
- Arsenal 4-1 West Ham REACTION: Arsene Wenger talks future and Alexandre ...Express.co.uk
- Arsene Wenger didn't just change English football, he changed the African game tooQuartz
- Departing Wenger hints at end-of-season reveal amid reports of sackingAOL UK
- Arsene Wenger backs Shkodran Mustafi to enjoy successful long-term future at ...The Independent
- Arsene Wenger breaks silence in first interview since Arsenal exit announcementSkySports
- Arsenal 4 West Ham 1: Alexandre Lacazette nets late brace in Arsene Wenger's ...The Sun
- Arsenal legend Bob Wilson tips Arsene Wenger to manage France as he gets set ...Daily Mail
- Arsenal legend Thierry Henry refuses to rule out replacing Arsene Wenger at ...The Sun