Three goals in five second half minutes saw Hearts see off a stubborn Arbroath side in the Scottish League Cup.
David Gold gave Arbroath a deserved 1-0 lead at half-time but Jordan McGhee and Osman Sow (two) were on the mark to make it 3-1 just after the break.
Substitute Martin Grehan gave the Lichties hopes of a late rally with a close range goal but Jamie Walker made it 4-2 in the dying moments.
New signing Sergio Cecilia Alvarez had the first shot on goal inside three minutes, firing at Jack Hamilton from outside the box but the young stopper was able to collect the weak effort.
Tidy play between Billy King and Sow saw the former take a shot from wide on the left but Graham Hay deflected it out for a corner.
King was the obvious danger man for the hosts and he drew a terrific save from Allan Fleming inside quarter of an hour, firing low across goal but the keeper got to it.
A Bobby Linn cross was just ahead of Lewis Coult at the back post - if the big man connected it was a certain goal.
Gold gave Arbroath the lead on 40 minutes after collecting a stunning through ball from Alvarez and slipping the ball past Hamilton.
Calum Paterson almost made it 1-1 seconds later with a great header but he struck the bar before Sow forced a sublime save from Fleming low to his right.
The Jambos were coming forward in waves after the break and it seemed like the Lichties defence couldn’t hold out for much longer.
And that was the case as Arbroath conceded three times in five minutes.
Alim Ozturk whipped the ball across goal for McGhee to hammer home for 1-1 before Sow scored an identical goal, converting from Sam Nicholson.
And it was a second goal for Sow after Nicholson was pulled down in the box for a penalty, and the Hearts striker made no mistake from the spot kick.
Linn then hit the post from a free kick as Arbroath tried to get back into the game, goalscorer Gold blasting the rebound over from close range.
McHattie sent another fierce ball across goal on 79 minutes but nobody could convert it.
Substitute Grehan pulled one back for Arbroath on 87 minutes, nodding in at the back post from a Lowdon cross.
Fleming made a late save - yet another stunning stop - from Walker as Hearts looked to snuff out Arbroath’s dim hopes of extra time.
And Walker was able to do just that a minute later, rolling the ball past Fleming for 4-2.