The Scottish champions started the game well but found themselves behind in the 12th minute when Andrei Finonchenko took advantage of some slack defending to score from close range.
Kris Commons rattled the bar with a thunderous drive in the 19th minute with the ball bouncing down on to the line but Neil Lennon's side struggled at times with the route-one approach taken by a home side who looked limited in other aspects of their game.
The visitors had the best of things again in the second half with James Forrest missing a chance from six yards but in the 77th minute powerful striker Sergei Khizhnichenko headed in a second to leave the shell-shocked Hoops having to make amends in next week's second leg in Glasgow.
Lennon, though, will be puzzled as to how his side have work to do against a basic team who themselves may wonder how they managed to emerge from the tie with a win.
Two of the Hoops' summer signings, Virgil van Dijk and Steven Mouyokolo, made their European debuts and started in central defence together for the first time as regular stopper Efe Ambrose dropped to the bench.
Mikael Lustig replaced Adam Matthews at full-back, the Wales defender recovering from a hamstring injury but only finding a place as substitute as Forrest came in for Beram Kayal.
Shakhter, the first Kazakh side to reach the play-off round of the competition, were playing 114 miles away from home in the 30,000-capacity national stadium, which was close to full with a couple of dozen Hoops fans in one corner behind a goal.
Celtic dominated the early stages on the artificial surface and indeed could have been two ahead before they fell behind.
The home side escaped in the fourth minute after Shakhtar keeper Aleksandr Mokin fumbled a Charlie Mulgrew corner and Van Dijk and Commons tried to get the ball in but it was scrambled away for another corner.
When Commons flighted the ball into the box from the other side, the Dutch defender powered a header in which was parried by Mokin and the Kazakh champions somehow survived again.
The home side were probably as surprised as anyone when they forced their way into the lead with what was a basic goal.
A long throw-in from the left by midfielder Gediminas Vicius was headed on by Nikola Vasiljevic and Finonchenko stole past Hoops midfielder Joe Ledley to knock the ball past Fraser Forster from close range.
The home fans could not believe their luck and they cheered every attack in the moments following but the Parkhead side stabilised and when Commons hit the woodwork it reminded them that Celtic remained a threat.
In the 29th minute, just after Shakhter defender Sergei Maliy had headed a cross from Aleksandar Simcevic over the bar from 14 yards, Georgios Samaras skimmed a header from a whipped-in Mulgrew free-kick just inches past the far post.
The Parkhead side had another opportunity four minutes from the break when Van Dijk got on the end of a Mulgrew corner but his header was directed straight at Mokin.
Celtic came out for the second half with some purpose and set about getting themselves level.
Hoops left-back Emilio Izaguirre should have netted in the 51st minute after taking a Commons pass and burrowing his way into the box but he slashed at his shot which flew over the bar.
Shakhter were defending in number and relying on the occasional break for respite.
One Shakhter break ended with Khizhnichenko getting a shot away which lacked the power to really test Forster but which brought thunderous cheers from the home fans, by now sensing a famous victory.
The Parkhead side continued to press and in the 72nd minute Forrest had a glorious chance when Izaguirre planted a cross on his head six yards from goal but the Scotland midfielder's header was straight at Mokin who gratefully blocked to safety.
The closing stages were frantic but again Celtic were slack when conceding the second.
Mouyokolo did well to block a goal-bound shot from Khizhnichenko but when the ball was crossed back in to the box by Vicius he steered a header past Forster from 10 yards.
The Glasgow giants were stunned and the final minutes passed in something of a blur for the visitors with Mulgrew heading over from six yards in the final minute.
After getting past Cliftonville and Elfsborg in the previous two qualifier, the Parkhead side now need to pull something special out of the bag next week, although in front of their own fans that is far from unlikely.
- Sports & Recreation
- Kris Commons
- James Forrest
- Charlie Mulgrew
- Aleksandr Mokin
- Sergei Khizhnichenko