Match ends, Heart of Midlothian 2, Hibernian 1.
Liam Boyce's extra-time penalty sent second-tier Hearts into the Scottish Cup final as they saw off Edinburgh rivals Hibernian in a Hampden thriller.
It was a particularly sore derby defeat for Hibs to take given they missed a spot-kick of their own just minutes earlier when Kevin Nisbet hit the bar.
Craig Wighton's fifth goal in four games broke the deadlock for Hearts, before Christian Doidge headed level.
But it was Hearts who reach the final for a second consecutive year.
Robbie Neilson's Championship outfit will meet the winner of Sunday's semi-final between Celtic and Aberdeen on 20 December back at Hampden.
- Hearts 'won't be put down' - Neilson
- Former Hearts defender Zaliukas dead at 36
- Podcast: All the fall-out from the derby
It was a semi-final that gripped you from the first to the 120th minute.
History appeared to favour Hearts. Despite last season's struggles, they won the most recent meeting at Easter Road.
They also triumphed in the last Scottish Cup duel in 2018, won the last semi-final between the pair 4-0 in 2006 and, of course, thumped their Edinburgh rivals 5-1 in the 2012 final - the last time they met at a neutral venue.
But Hibs are a division higher, had lost just once in nine games, and had not conceded in three. They walked into Hampden as favourites and, in the first 30 minutes, the big chances fell their way.
Kyle Magennis had a goal-bound shot blocked. Then Martin Boyle's cross was met perfectly by Nisbet, only for goalkeeper Craig Gordon to stick his left hand out and deny him.
Olly Lee and Jamie Walker had half chances for Hearts, but it was Hibs who looked more dangerous as the game wore on. They had Hearts pinned back, Boyce having to clear off his own line at one point.
But Hearts turned the game on its head on the hour. Neilson made a double change, pushed Wighton further forward, and within minutes was rewarded when the attacker met Lee's cross.
But just as Hibs fans thought this was going to be another Hampden derby horror show, Doidge rose highest at a free-kick to loop in a header and restore parity.
The fire had been stoked. Lee placed the ball into the path of Wighton, who could have scored a second but instead sent it wide. Doidge played a poor pass in a good position. Hearts romped forward but Boyce trundled a low shot wide.
And, in the dying seconds of normal time, Hibs were left furious when Doidge and Boyle both hit the deck in the box. Referee Willie Collum instead awarded a free-kick to Hearts.
Into extra time it went. Hibs started on the front foot. Alex Gogic's shot was awkward for Gordon, who parried it on to a post. And he again had to be alert when Joe Newell's shot took a deflection.
More drama was coming. Newell threw himself to the floor and earned Hibs a penalty despite there appearing to be little contact from Mihai Popescu. But Nisbet cracked his penalty against the crossbar.
Then, within minutes, Hearts got a penalty of their own when Aidan White was fouled by Paul McGinn. Boyce made no mistake, thumping it home.
Doidge's acrobatic overhead kick forced another great save from Gordon as Hibs refused to give it up, but Hearts held on for yet another famous Hampden win over their old foes.
Man of the match - Craig Gordon
What did we learn?
Both sides had their character tested. For the first hour, Hearts had lived dangerously and had Gordon to thank for keeping them level.
But after Neilson's changes, they grew as an attacking force with a display that belied their Championship status. And they showed their mettle in extra time.
Hibs, too, fought back after falling behind. But they were left to rue a glut of missed chances as they suffered more Hampden heartbreak.
What did they say?
Hearts manager Robbie Neilson: "It was a rollercoaster ride and there was a lot of nail biting in that extra-time, but we've managed to get the win and beat our arch rivals here at Hampden again.
"At the time, I don't think any of them were penalty kicks, but it's one of them - it's very difficult for the referee out there. We rode our luck a bit for our penalty but held our nerve for ours."
Hibs manager Jack Ross: "We're sore. We put a lot into the match and there's fine margins in football all the time. We came out of the wrong side of those margins today.
"There's no magic words to take the pain away from Kevin Nisbet. He's got the courage to take the penalty and he'll have the courage to do so again in future. He's hurting right now, but he'll be fine."
Hibernian travel to Aberdeen on Friday (19:45 GMT) in the Premiership before Hearts host Inverness Caledonian Thistle on Saturday in the Championship (15:00). And the Tynecastle side will be the ones in the Scottish Cup final on 20 December.
- 2SmithBooked at 69mins
- 26HalkettBooked at 80mins
- 28PopescuBooked at 44mins
- 8LeeSubstituted forHendersonat 97'minutes
- 16HallidayBooked at 63minsSubstituted forIrvingat 117'minutes
- 15WightonSubstituted forWhiteat 83'minutes
- 7WalkerSubstituted forNaismithat 56'minutes
- 11RobertsSubstituted forHaringat 56'minutes
- 4HanlonBooked at 96mins
- 25DoigSubstituted forMackieat 87'minutes
- 13GogicBooked at 113minsSubstituted forMallanat 115'minutes
- 7MagennisSubstituted forMurphyat 61'minutes
- William Collum
- Shots on Target
Second Half Extra Time ends, Heart of Midlothian 2, Hibernian 1.
Steven Naismith (Heart of Midlothian) wins a free kick in the attacking half.
Foul by Martin Boyle (Hibernian).
Foul by Liam Boyce (Heart of Midlothian).
Paul McGinn (Hibernian) wins a free kick in the attacking half.
Liam Boyce (Heart of Midlothian) wins a free kick in the attacking half.
Foul by Sean Mackie (Hibernian).
Substitution, Heart of Midlothian. Andrew Irving replaces Andrew Halliday because of an injury.
Andrew Halliday (Heart of Midlothian) wins a free kick in the defensive half.
Foul by Paul McGinn (Hibernian).
Substitution, Hibernian. Stephen Mallan replaces Alexander Gogic.
Attempt missed. Joe Newell (Hibernian) right footed shot from the centre of the box is high and wide to the right.
Attempt saved. Christian Doidge (Hibernian) left footed shot from the centre of the box is saved in the top right corner.
Alexander Gogic (Hibernian) is shown the yellow card for a bad foul.
Euan Henderson (Heart of Midlothian) wins a free kick in the defensive half.
Foul by Alexander Gogic (Hibernian).
Goal! Heart of Midlothian 2, Hibernian 1. Liam Boyce (Heart of Midlothian) converts the penalty with a right footed shot to the bottom left corner.
Penalty Heart of Midlothian. Aidan White draws a foul in the penalty area.
Penalty conceded by Paul McGinn (Hibernian) after a foul in the penalty area.