Munich - Corentin Tolisso struck twice as Bayern Munich avenged September's defeat at Paris Saint-Germain with a 3-1 victory in Bavaria on Tuesday, but the French side finished top of Group B.
With both teams already through to the last 16, Bayern needed to win by four goals to usurp PSG having lost 3-0 at the Parc des Princes.
Bayern raced into a 2-0 half-time lead thanks to goals by Robert Lewandowski and Tolisso.
Kylian Mbappe calmed the visitors' nerves just after the break before Tolisso scored a superb third for Bayern.
The result means the big-spending Parisians finish as group winners with a better goal difference across the two head-to-head matches, while the German champions restored pride as they matched PSG's tally of 15 points.
It was a second straight defeat for Unai Emery's PSG after a 2-1 loss at Strasbourg in Ligue 1 on Saturday, having started the season with a 21-match unbeaten run in all competitions.
"The key to our success was the attitude of the whole team," said Bayern head coach Jupp Heynckes, who stepped in when Carlo Ancelotti was sacked in the wake of the Paris defeat.
"Tactially, we weren't just clever in the way we played, but also street-smart.
"Overall, we played a very good game and implemented what we set out to do."
Bayern set about settling the score in determined fashion at Munich's Allianz Arena.
PSG's Germany midfieder Julian Draxler admitted the home side were the better team on the night.
"Bayern did well, you can see that they are still up there amongst the best teams in Europe," said Draxler.
Under Heynckes, who coached Bayern to the 2013 treble, the Germans look a different side to the one outplayed by the French league leaders in September.
Bayern's head coach pulled a few surprises before kick-off by leaving out Germany stars Jerome Boateng and Thomas Mueller, plus midfielders Javi Martinez and Arturo Vidal.
Nevertheless, the hosts took the lead after just eight minutes when Franck Ribery's pass released James Rodriguez down the left.
The Colombian's cross was headed towards goal by Kingsley Coman and Lewandowski turned and slammed his shot past PSG goalkeeper Alphonse Areola to the delight of the home crowd, after Dani Alves played him onside.
Bayern started taking control of possession and the away defence became decidedly jittery when Tolisso doubled the lead just before the break.
Rodriguez again did the damage with a cross from the left and the French midfielder hammered his header past Areola.
Just as Bayern fans were starting to believe in the dream 4-0 win, PSG pulled a goal back shortly after the restart.
Marco Verratti started the move, floating a pass into the penalty area where Edinson Cavani controlled the ball and picked out Mbappe, who made no mistake with his header.
With belief flowing through the visitors' ranks, Mbappe forced Bayern goalkeeper Sven Ulreich into a good save as PSG attacked in waves.
Coman created Bayern's third goal as he sprinted clear of Alves and squared the ball to an unmarked Tolisso, who hit his shot cleanly past Areola on 69 minutes.
However, Bayern's double goal-scorer was lucky to stay on the pitch during an attack in the area soon after.
Having already seen a yellow card in the first half, Tolisso clearly dived as Areola slid for the ball.
Referee Cuneyt Cakir waved away the furious protest by Alves and Tolisso stayed on the pitch to help Bayern close out the win.