Valencia - Bayern Munich needed a late Thomas Mueller goal to come from behind and seal a 1-1 draw at ten-man Valencia on Tuesday which put both teams in the Champions League's knock-out phase.
After Lille's 2-0 win at BATE Borisov in Belarus earlier, both teams are now guaranteed passage into the knock-out phase and are level on 10 points at the top of Group F after the draw at Estadi de Mestalla.
With BATE third in the group on six points, neither team can now be denied a place in the last 16.
Midfielder Sofiane Feghouli had put Valencia ahead with time running out, but Bayern held their nerve as Germany midfielder Mueller netted the equaliser.
"It was a fantastic performance from us," said Feghouli.
"Although we wanted to win for our fans, we will leave here satisfied.
"We still want to finish first in the group so winning our last match is vital."
The draw in Valencia means the final round of matches in a fortnight are just for pride when Bayern host BATE in Munich and Valencia are at Lille.
"I'm glad we scored the equaliser," said Bayern's Germany star Mario Gomez, who made his first appearance of the season in a Munich shirt.
"Valencia is a home strong team, when they had the ball, we didn't get it back fast enough."
Valencia were reduced to ten men after only 33 minutes when defender Antonio Barragan, who had brought down France's Franck Ribery on 20 minutes, slid into Bayern's David Alaba and earned an immediate red card from referee Howard Webb.
Bayern, who are bidding to reach their third Champions League final in four years at Wembley next May, enjoyed the lion's share of possession, with 65 percent, and created 17 shots on goal compared to Valencia's nine.
Despite the numerical deficit, the hosts took the lead with just over 15 minutes left when Feghouli cut in from the right wing and fired home from the edge of the area.
The ball took a deflection off the hand of Bayern defender Dante, which wrong-footed Bayern goalkeeper Manuel Neuer as it flew into the net on 77 minutes.
Munich coach Jupp Heynckes responded immediately by sending on Gomez for his first appearance in a Bayern shirt this season and his first compeitive match since the Euro 2012 semi-final defeat to Italy.
Ankle surgery in August had kept him out for three months, but Heynckes opted to field two strikers with Gomez alongside Croatia's Mario Mandzukic, who came on for Peru veteran Claudio Pizarro ten minutes before the opening goal.
Bayern were behind for just five minutes and Heynckes' change of tactics paid off as both Mandzukic and Gomez left a cross from captain Philipp Lahm on 82 minutes for Mueller to fire home and put Bayern into the knock-out phase.