Substitute Ilhan Mansiz scored a golden goal four minutes into extra-time to give Turkey a 1-0 victory over Senegal and a place in the World Cup semi-finals for the first time.
Ilhan shot home on the half-volley from eight metres out after receiving a cross from Umit Daval on the right to end the run of the tournament's giant-killers..
Turkey will face four-times World champions Brazil in Saitama on Wednesday.
The two sides had failed to score in regulation time despite a fast-flowing match in which Turkey created the better chances against the African debutants.
After a cagey opening quarter, Turkey came to life and created several good chances in the first half, most of them falling to out-of-form striker Hakan Sukur.
The 30-year-old squandered his best opportunity after 27 minutes when Hasan Sas's pass found him unmarked five metres out but Turkey's most capped player failed to control the ball with the goal gaping.
Senegal defender Omar Daf superbly cleared a Yildiray Basturk header off the line a minute before the interval but the powerful Africans also had their moments.
Striker El Hadji Diouf had one effort ruled out for off-side and just before the break only a fine tackle by Alpay Ozalan denied the African footballer of the year his first goal of the tournament after a sparkling run by Henri Camara.
Senegal, in their first World Cup appearance and trying to become the first African side to reach the last four, had shocked the soccer world by defeating holders France in the tournament's opening game.
Draws against Denmark and Uruguay ensured they made the second round, where they defeated Sweden 2-1 in extra time with a golden goal.
After a controversial defeat by Brazil, the Turks did well to finish second in their group and defeated co-hosts Japan 1-0 in their second round match to reach the last eight for the first time.
Diouf and Basturk both threatened to break the deadlock at the start of the second half.
Umit Davala, scorer of two goals in the tournament, began to cause problems for Senegal down the right flank but Hakan Sukur continued to disappoint and after 67 minutes he was substituted.
His replacement Ilhan Mansiz immediately threatened with a shot just over the bar.
Turkey were having the better of it but the game remained desperately tight with so much at stake and it was no surprise when extra time arrived with the stalemate unbroken.