DFB-Pokal: Borussia Dortmund 3 Hoffenheim 2
Dortmund, last year's beaten finalists, were made to work hard for their place in the last four, despite Neven Subotic giving them an early lead with a smart strike.
Kevin Volland's fierce finish equalised matters soon after and Roberto Firmino capitalised on a mistake from Subotic to turn things in the visitors' favour before half-time.
Pierre-Emerick Aubameyang levelled things up once more in 57th minute as he converted from Erik Durm's cross and, although Dortmund could not finish things off in normal time, Kehl did so spectacularly after 107 minutes.
The veteran midfielder let fly with a magnificent volley from 30 yards that cannoned off the post and in to keep Dortmund's hopes of silverware alive.
Dortmund's early dominance of possession was rewarded in the 19th minute when Subotic hooked a volley in off the post from Jakub Blaszczykowski’s corner.
But the hosts' lead lasted just two minutes, Volland answering in fine fashion as Dortmund failed to defend a corner at the other end.
Volland powered Sebastian Rudy's floated delivery into the bottom-right hand corner with a perfectly struck volley.
And Hoffenheim then completed the turnaround, Subotic going from hero to villain in the 27th minute with a sloppy piece of defending.
Subotic lost possession to Firmino inside his own half and the Brazil forward - who netted his first goal for his country in the recent international break - made no mistake by racing away and coolly lifting the ball over Mitchell Langerak.
Dortmund went close to levelling three minutes into the second half when Aubameyang fired narrowly wide of the left-hand post, before Ilkay Gundogan shot straight at Oliver Baumann at the end of a free-flowing move.
However, Aubameyang then atoned for his earlier miss, meeting Durm's cross with a powerful header that left Baumann helpless.
The Hoffenheim goalkeeper was equal to Aubameyang's next effort, though, which he turned wide at the near post as Dortmund pressed for a winner.
Baumann thwarted Subotic 12 minutes from time, the Serb seeing his header from another Blaszczykowski corner brilliantly turned over the crossbar.
Eugen Polanaski was denied at the other end by Langerak and Firmino lashed wide late on as both teams searched for a winner, with normal time fittingly ended by a Baumann save from Blaszczykowski.
Dortmund dominated the first period of extra time, and were finally rewarded two minutes into the second period by Kehl's superb drive after Hoffenheim had failed to clear a cross into the box.
Kevin Kampl then shot over the bar from point-blank range after Baumann had kept out a Shinji Kagawa header but that mattered not as Dortmund stood firm to seal progression in dramatic fashion.
In Tuesday's other quarter-final, a second-half penalty from Ricardo Rodriguez gave Wolfsburg a 1-0 home win over Freiburg.