The Hoops coped well against the Russian champions in Wednesday's third qualifying round first-leg tie at the Luzhniki Stadium.
Hartley put Celtic in front on the bouncy plastic pitch with a well-placed header from Scott McDonald's right-wing cross after 21 minutes. It was the 30-year-old Scotland midfielder's first goal for the Glasgow giants since his move from Hearts in January.
Spartak ace Roman Pavlyuchenko levelled just before the break and although the hosts went close in the second half, Bhoys goalkeeper Mark Brown was in fine form.
Pavlyuchenko had the ball in the net from six yards out early on after Brazilian star Welliton had left John Kennedy for dead on the left-hand side of the box. The striker produced a neat finish, hooking the ball in after rushing ahead of the pass, but it was disallowed for offside.
And 12 minutes later, Hoops debutant McDonald beat the offside trap to cross for Hartley to head the visitors into the lead.
McDonald looked suspiciously offside when he latched onto a Shunsuke Nakamura pass down the right-hand side.
But the little striker looked up and crossed a delightful ball to the arriving Hartley, who bulleted a header from 10 yards past Stipe Pletikosa and into the corner of the net.
However, three minutes from the interval, the home side were level. Roman Shishkin's cross from the right was met by Pavlyuchenko and although his close-range header was parried by Brown, the ball escaped over the line.
Spartak should have taken the lead in the 65th minute when Welliton delivered an inch-perfect cross from the right to strike partner Pavlyuchenko.
However, from only eight yards out, the tall Moscow player headed downwards and the ball bounced up from the artificial turf and went over the bar.
Soon after, Scott Brown timed his run just right to collect substitute Aiden McGeady's clever pass, which dissected the Spartak defence and found the midfielder all alone, 12 yards from goal.
Brown also nudged wide of Pletikosa and looked to have a simple task of slotting home, but he turned too slowly and was unable to gain control as the Spartak keeper recovered to snatch the ball.
Radoslav Kovac's header bounced off the Celtic bar in the dying stages as the Scottish champions held on.
The second leg is at Parkhead in a fortnight's time.
Vi bruger cookies for at kunne give dig den bedste oplevelse. Ved at bruge vores side accepterer du brugen af cookies. Du kan læse mere i vores persondatapolitik.