Real Madrid saw off a stirring Chelsea fightback to book their place in the Champions League semi-finals following a 3-2 defeat after extra-time in a scintillating second leg at the Santiago Bernabeu on Tuesday to go through 5-4 on aggregate.
Chelsea had looked on course to complete an astonishing comeback after taking a 3-0 lead in their quarter-final second leg with goals from Mason Mount, Antonio Rudiger and an excellent individual effort from Timo Werner.
Yet the hosts came roaring back, with Rodrygo finishing from a superb pass by Luka Modric to level the tie 4-4 on aggregate and force extra-time when Karim Benzema headed home to decide a remarkable encounter.
Real Madrid will now face either Manchester City or local rivals Atletico Madrid in the last four, with the English side taking a 1-0 lead into their quarter-final second leg in Spain on Wednesday.
It was a Champions League night for the ages at a packed stadium as a brilliant Chelsea came within 10 minutes of completing a rescue act that their manager Thomas Tuchel had said they were unlikely to accomplish.
His team took the game to Real Madrid as they looked to turn around a two-goal deficit from the first leg and it took only 15 minutes for Mount to open the scoring from a through ball behind the defence.
Chelsea were even more aggressive after the break and scored their second in the 51st minute when Rudiger guided home a header from a Werner corner to level the tie 3-3 on aggregate.
Four minutes later, Werner found Marcos Alonso inside the area and he thrashed his finish into the top corner only to see his effort chalked off by the video assistant referee who had spotted a handball from the Spanish left back.
With the visitors on top, however, it was only a matter of time until they scored their third which arrived in the 75th minute from a brilliant piece of individual skill from Werner, who left two opponents on the ground before dispatching a precise shot past Courtois and inside the far post.
In the very next move, Kai Havertz was denied by former Chelsea keeper Courtois, who made a magnificent save to stop his close-range header.
Yet just when Real looked completely out of the game, Modric worked his magic, finding substitute Rodrygo at the far post with a delightful pass with the outside of his boot that the Brazilian volleyed past Edouard Mendy in the 80th to take the game to extra time.
That was the cue for Vinicius Jr and Benzema to show up and rescue Real Madrid from what would have been one of the biggest shocks they had ever suffered at home.
Vinicius worked his way inside from the left corner, and sent a lovely cross onto Benzema's head, and the Frenchman bulleted it past Mendy as the ecstatic home fans exploded with joy.
"It was another incredible night, what a sweet tasting loss," Modric told Movistar Plus.
"We didn't give up until the end. Despite going 0-3, I don't think we played a bad game. Another night of suffering, but the important thing is that we have qualified."
Bayern shocked by late equaliser as Villarreal reach semis
Bayern Munich were stunned as underdogs Villarreal scored an 88th minute equaliser through substitute Samuel Chukwueze to snatch a 1-1 draw and reach the Champions League semi-finals with a 2-1 aggregate win over the Germans.
Six-time European champions Bayern, who had won 12 of their previous 13 home games in the competition, levelled the tie when Robert Lewandowski drilled the ball in off the post after 52 minutes with his 13th Champions League goal of the season.
Yet despite controlling the game they failed to score again.
Instead it was Villarreal, semi-finalists in 2006, who netted against the run of play with Chukwueze beating goalkeeper Manuel Neuer with a left-foot effort to silence the home crowd.
Villarreal will play Liverpool or Benfica in the last four, with the English side leading 3-1 after the first leg in Portugal, with the return at Anfield on Wednesday.
"We feel a lot of happiness. Ever since the draw paired us with Bayern, we have been telling ourselves that we could do it," Villarreal forward Gerard Moreno said. "The belief and the way this team competes has helped us to achieve it."
"In the first leg we made the mistake of not finishing the tie, and all the comments serve as motivation for us. They made the mistake today of not killing us off and we took advantage of that."
Bayern coach Julian Nagelsmann fielded an attacking formation with Jamal Musiala, Lewandowski and Thomas Mueller up front but they had only one effort on target in the first half with Musiala's weak header on the half hour mark.
Villarreal, unchanged from last week's 1-0 win in Spain, were comfortable with staying back and efficiently absorbing the waves of Bayern attacks while remaining a threat on the break.
But Unai Emery's team looked out of sorts after the break, piling up errors and losing possession as Bayern instantly upped the pressure.
Home defender Dayot Upamecano should have done better when his shot from eight metres flew over the bar in the 49th minute but Lewandowski did not miss three minutes later.
Bayern intercepted a sloppy Villarreal pass and the Pole finished the quick move with a low drive off the post.
The Bavarians, who had scored a total of 20 goals in their previous four home games in the competition this term, came close to a second goal in the 71st but Mueller's diving header went wide.
It was left to Villarreal, Europa League winners last year, to punished the hosts with a sucker punch through Nigeria winger Chukwueze, to reach the semis for the first time in 16 years.