Odsonne Edouard fired Celtic through to the Europa League group stage as Neil Lennon's Scottish champions earned a 1-0 win at Sarajevo.
The visitors took charge of a tense play-off match in the second half, and Edouard, their former Paris Saint-Germain academy striker, was the man who made the difference.
He scored in the 70th minute after Ryan Christie saw a shot repelled.
It meant that Lennon, whose team's Champions League qualifying hopes were ended by a home defeat to Ferencvaros, avoided the ignominy of Celtic being knocked out of the Europa League, too, before the competition begins in earnest.
Celtic had few sights of goal in the first half, but Ryan Christie sent a 25-yard strike a couple of feet over the bar in the 63rd minute as the Hoops stepped it up.
They went close again five minutes later when a corner from the left reached Hatem Abd Elhamed just beyond the penalty spot, and his volley flew just wide of the right post.
The breakthrough came soon afterwards, Edouard firing into the Sarajevo net after Christie was denied by home goalkeeper Vladan Kovacevic.
Christie drew another save from Kovacevic with a stinging 20-yard shot as Celtic sought a second goal to strengthen their position.
Edouard played in Christie for a further opportunity after a surging run, but the winger could not test Kovacevic, and Jeremie Frimpong sent a shot just wide.
One goal was enough, however, to put Celtic into Friday's draw.