Croatia striker Eduardo, sold during the summer, netted a fine consolation goal on the return to his former club with seven minutes left, which brought a round of applause from the home fans.
Arsenal now head out to Donetsk in a fortnight knowing a point from their remaining three matches, one at home, would probably secure a top-two finish.
The Gunners had already chalked up some nine goals in the Champions League, hitting new boys Braga for six in their opening match.
However, it was not expected to be an easy ride against the Ukrainian champions, who had lost only one of their last 26 matches in all competitions.
Following the anticipated cagey start, Arsenal created an opening when Fabregas – out since mid-September with a hamstring problem – floated the ball just over Chamakh.
Shakhtar, however, were breaking up play well in midfield before defender Razvan Rat sent a 25-yard effort wide.
Arsenal then took the lead on 19 minutes with a scrappy goal, following a terrible error by the Shakhtar goalkeeper. Pyatov was under no pressure when he came to collect a corner, but contrived to drop the ball in the six-yard box.
Emmanuel Eboue reacted quickly to stab the loose ball goalwards, which Song flicked on, before Olexander Kucher’s clearance ricocheted back off the Cameroon midfielder and over the line.
Nasri almost made it 2-0 moments later with a long-range effort which flew straight at Pyatov and this time the Shakhtar keeper just about held on.
Wilshere – serving a three-match domestic suspension after his much-talked about red card against Birmingham – was late with a challenge on Tomas Hubschman which left the Shakhtar midfielder in a heap. However, Norwegian referee Svein Oddvar Moen deemed a stern lecture the only action needed.
Shakhtar had a couple of long-range efforts which failed to hit the target.
It proved costly as Arsenal doubled their lead on 42 minutes.
Eboue and Song worked the ball down the right, before the midfielder sent a cross into the penalty area, which deflected through to Nasri on the far side.
The in-form French winger sidestepped Darijo Srna before smashing the ball past Pyatov.
Shakhtar could have reduced the deficit at the start of the second half when Song lost possession and Henrik Mkhitaryan fed Luis Adriano, who sprinted into the box, but Lukasz Fabianski made a smart save.
Arsenal were then gifted a third goal from the penalty spot on the hour after Adriano had wrestled Johan Djourou to the ground.
Fabregas stepped up to smash the ball into the top-left corner – and lifted up his shirt to reveal a Catalan birthday message for his mum. With the job done, the Spanish World Cup winner was given a rest as Brazil youngster Denilson came on.
There was then a standing ovation from the home fans as Eduardo – who had battled back from an horrific broken leg and dislocated ankle at Birmingham in February 2008 – was introduced for Adriano.
It was exhibition stuff from Arsenal now, as Chamakh and Tomas Rosicky exchanged passes to release Wilshere into the area, and he chipped in number four on 66 minutes.
Morocco striker Chamakh then sprang the offside trap, played on by the full-back, to slot home his sixth goal of the campaign.
With 20 minutes left, Arsenal sent on Andrey Arshavin and Theo Walcott – making his first appearance since injuring ankle ligaments when paying for England during September.
But perhaps fittingly it was Eduardo who had the final say, volleying home a well-taken effort in the closing stages, which he did not celebrate while receiving applause from the home fans.