The Warriors looked down and out when they trailed by 10 points at the interval - but they produced a stunning fightback to clip the wings of the Welsh high-flyers by 29-26.
Ospreys could not have dreamed of a better start as they surged ahead after barely a minute's play.
But the guts and determination of Glasgow shone through when it mattered most as they hit back to win the contest.
On a sandy and parched surface, the hosts made a hash of clearing the danger from their own half and first to react was former All Blacks scrum-half Justin Marshall.
Winger Shane Williams seemed to be covered by Thom Evans, but somehow he squeezed past him. Although he was floored a couple of metres short of the line, Williams had sufficient momentum to reach the target.
James Hook slotted the conversion from the widest possible angle to give his side a further confidence boost.
Glasgow hit back in positive style, forcing the Welsh outfit to wander offside in their own 22-zone. Scotland outside half Dan Parks calmly banged over the tricky penalty to reduce the early leeway.
Hook was soon back in the spotlight at the other end to restore the Ospreys' advantage with a crisply struck effort from almost 40 metres.
The penalty tit-for-tat continued as Williams was guilty of failing to release the ball in contact. It wasn't Parks' best ever kick - but it had just enough oomph to clear the crossbar from 35 metres range.
Ospreys raced back into attack to carve out a second touchdown three minutes later and the Glasgow defence went missing as full-back Lee Byrne ambled round at least two markers before cruising over.
There was disappointment for the visiting fans, however, when Hook was wide with the straightforward conversion bid.
Ospreys were then reduced to 14 men, prop Adam Jones ordered to the sin-bin for killing the ball at a ruck in the shadow of the posts - leaving Parks to slot the simple kick.
The visitors recaptured the momentum through a moment of slackness from Rory Lamont, who spilled the ball as he tried to tap it after making a safe mark.
And Hook rediscovered his touch by thumping over a long-range penalty after lineout obstruction by former Ospreys lock Andy Newman.
Then came one of Parks' moments of madness. Having pinned back the Ospreys for a string of phases, he fired out a crooked long pass.
It bounced perfectly for speed king Williams, who was never going to be caught on his 80-metre sprint to glory.
Hook's conversion crashed back off the woodwork before he left the fray for attention to a blood injury.
Shaun Connor came off the bench to add another penalty, leaving the home brigade with a mountain to climb.
And it was villain-turned-hero Parks who started the repair mission with a try in the wake of brilliant work by Graeme Beveridge.
Parks followed up to make it a seven-pointer to keep his side in the hunt at the break.
Then he stroked over another penalty for line-out offside to set up an exciting finale.
Scotland winger Nikki Walker streaked clear, thinking he was heading for another Ospreys try - but referee George Clancy ruled the Glasgow defence had been obstructed in midfield.
The Warriors capitalised on the let-off by setting up a second touchdown of their own from substitute centre Graeme Morrison - and Parks' wide-angled conversion squared the contest.
And the roars of the home fans were even louder when Parks hammered over another penalty from the halfway line to clinch victory for Glasgow.