It was an attritional affair in the first of the French double-header which Glasgow had to win to have any hope of overhauling defending European champions Leinster, who this afternoon won at Bath, at the top of the standings.
Three players were sin-binned inside the opening 36 minutes - two for Montpellier and one for Glasgow - but the Warriors' half-time lead was only 12-10.
Montpellier's try came through Eric Escande after prop Jon Welsh had been sin-binned, while Martin Bustos Moyano added five points from his boot.
Duncan Weir kicked four penalties before Ruaridh Jackson was called up for the final 23 minutes.
Scotland fly-half Jackson slotted a fifth penalty with 12 minutes remaining before Federico Aramburu scored a try six minutes from time.
It was enough for Glasgow to seal a second win from three Heineken Cup games this term, despite Montpellier substitute Masi Matadigo's late try which secured a losing bonus point.
Montpellier travelled without captain Fulgence Ouedraogo, Georgian powerhouse Mamuka Gorgodze and inspirational fly-half Francois Trinh-Duc, but all three should be back for Saturday's return in southern France.
However, there was still enough quality to concern Glasgow - particularly Lucas Gonzalez Amorosino, the Argentinian back who broke Scottish hearts with a last-gasp try in the Rugby World Cup meeting in Wellington in September.
Rory Lamont, who was making his second Warriors debut after recently re-signing, was not involved against the Pumas and today was playing his first game since the Georgia World Cup clash after being released from Toulon, along the Mediterranean coast from Montpellier.
In the seventh minute, Pierre Berard was sin-binned for taking Aramburu out in the air, but all Glasgow had to show for their extra man was Weir's penalty after 13 minutes.
Bustos Moyano levelled before Weir kicked Glasgow in front again following a Montpellier infringement, but only after missing an earlier opportunity.
Paul Bosch's break then enabled the French visitors to pile pressure on the Glasgow line.
A series of scrums followed, three of which resulted in penalties, the last of which saw loosehead Welsh yellow carded.
After a Glasgow reshuffle and from the next set-piece, Montpellier scrum-half Escande darted through a hole in the home defence. Bustos Moyano converted.
An offside at halfway was punished by Weir's third penalty before Montpellier had a second player sent to the bin.
Barclay was taken out in the air at a lineout and Vassili Bost was yellow carded after hindering the Glasgow openside on the floor.
Weir kicked his fourth penalty and, after Welsh's return, Glasgow had an extra man for the opening six minutes of the second half.
The Glasgow fly-half missed the opportunity to edge his side further ahead three minutes into the second half and a Gray burst for the line was spoiled when Wilson dived in at the resulting ruck five metres out, conceding a penalty.
Bost returned with Montpellier having conceded only three points in his absence.
Stuart Hogg then made a fine break down the left, but was hauled down with Weir unopposed outside him and the ball went forward, relieving the pressure.
Glasgow turned to the bench, with Jackson replacing Weir at fly-half, while Lamont made a couple of promising bursts which were halted by the visitors.
Jackson kicked Glasgow five points clear before the Warriors struck with a clinical backs move from left to right, Hogg coming into the line before feeding Aramburu to race over in the corner. Jackson missed the conversion, leaving five minutes for Glasgow to survive.
There was no dramatic late twist from Amorosino, but Matadigo raced down the right to score and earn the bonus point.
A cool looking all black rugby cleat with the high performance adidas is known for. Get in the Gear!
Wear the crest of the British and Irish Lions on your t-shirt. A great look for the summer.
The All Blacks Performance t-shirt is black with hints of blue from the training jersey. Very Cool.
The New Zealand All Blacks training jersey for 2013/14. Get in the Gear!