|Bath (6) 20|
|Tries: penalty 2 Cons: Ford 2 Pens: Ford 2|
|Glasgow (7) 15|
|Tries: Dunbar, Vernon Con: Russell Pen: Russell|
Bath survived a desperate late assault from Glasgow to win a West Country thriller and reach the Champions Cup last eight as Pool Four winners.
Glasgow went in front via Alex Dunbar's fine converted try but George Ford's two penalties made it 7-6 at the break.
Richie Vernon's stunning try extended Glasgow's lead before Bath went ahead for the first time via a penalty try.
A Finn Russell penalty put Glasgow back in front but the power of the Bath pack earned a decisive second penalty try.
Bath are joined in the last eight by Northampton, Wasps and Saracens - the first time four English clubs have made the knockout stages of Europe's top tier competition since the 1997-98 season - and will travel to three-time champions Leinster for their quarter-final.
|Champions Cup quarter-finals (3/4/5 April)|
|Racing Metro v Saracens|
|Toulon v Wasps|
|Clermont Auvergne v Northampton|
|Leinster v Bath|
Toulouse went into Sunday's games as Pool Four leaders but their 27-26 defeat away to fellow French club Montpellier - who had lost all five of their previous matches in the tournament - handed the pool to Bath.
It could have been a vastly different story though, with Glasgow coming within inches of what would surely have been a match-winning 79th minute try.
Glasgow full-back Sean Maitland looked certain to score after a thunderous final charge by the visitors, but a superb tackle by Jonathan Joseph, with help from Sam Burgess, stopped him no more than a few inches from the line.
When Glasgow recycled the ball and switched it to the right, South Africa flanker Francois Louw won a superb turnover, and with it went Glasgow's hopes.
The visitors were excellent throughout the match - lively with ball in hand, tigerish in defence and a constant nuisance at the breakdown.
The only area where Bath had dominance was in the scrums and in the end it was the pack's superiority that secured victory.
|European Champions Cup Pool Four|
Glasgow's lively start was rewarded with a fine try from a scrum, with an inside pass putting DTH van der Merwe through a yawning gap and the winger feeding Scotland centre Dunbar - later to go off injured, as did Bath's England centre Kyle Eastmond - to stride over untouched for a converted try.
A combination of line-out errors and poor handling prevented Bath from building any momentum, but they finally began to get to grips with the game and two George Ford penalties made it 7-6 at the break.
Any thoughts the hosts had of taking control were swiftly dispelled as Glasgow mounted a dazzling long-range counter-attack which featured half the team before number eight Vernon went over in the right corner for an unconverted try.
The hosts finally went ahead with just under half an hour to play as a driving maul earned them a penalty try, making the conversion a formality.
Glasgow hit back immediately through a Russell penalty but a second penalty try for the hosts, this time from a scrum that rumbled forwards at pace, gave Bath a winning lead they just managed to maintain thanks to erocious last-gasp defence.
|Semi-final draw (to be played 17/18/19 April)|
|Toulon/Wasps v Leinster/Bath|
|Clermont Auvergne/Northampton v Racing Metro/Saracens|
Bath head coach Mike Ford told BBC Sport:
"There were small margins, they put us under pressure but we did well when it mattered. They put us off our game but we did well to win.
"But I said to them 'well done' as no-one has ever lost their first two games and finished up pool winners.
"I was very nervous but I trusted the players 100%. Glasgow played very well and probably played better football than us but no-one will fancy playing us in the quarter-finals."
Glasgow head coach Gregor Townsend told BBC Sport:
"I feel proud, we knew it was tough. We started positively and carried that on.
"We had the ambition to win the game but we came up short.
"We need to play better for longer. It's all about building confidence and we need to do that for the rest of the season."
Bath: Watson, Agulla, Joseph, Eastmond, Banahan, Ford, Cook, James, Webber, Wilson, Hooper, Day, Garvey, Louw, Houston.
Replacements: Burgess for Ford (65), Stringer for Cook (62), Auterac for James (49), Batty for Webber (49), Thomas for Wilson (49), Attwood for Day (55), Fearns for Houston (62), Devoto for Eastmond (15)
Glasgow: Maitland, Seymour, Bennett, Dunbar, van der Merwe, Russell, Pyrgos, Reid, MacArthur, Cusack, Gray, Kellock, Nakarawa, Brown, Vernon.
Replacements: Horne for Dunbar (45), Matawalu for Pyrgos (69), Yanuyanutawa for Reid (41), Welsh for Cusack (41), Eddie for Kellock (62), Lamont for Van der Merwe (62)
Not Used: K Bryce, Murchie.
Sin Bin: Kellock (52).
Ref: John Lacey (Ireland).