Jim McIntyre's cheeky late penalty secured Uefa Cup football for Dunfermline after victory in a scintillating Scottish Cup semi-final.
Jim McIntyre chipped the ball home with four minutes left
Only 8,500 turned up to the replay at the national stadium, but the stay-away fans missed a cracker.
The Pars' Phil McGuire and Hibs' Scott Brown both had efforts cleared off the goal line during a first half of end-to-end action at Hampden Park.
And McIntyre chipped the winner after Adam Hammill was felled by Chris Hogg.
Hammill had returned to the starting line-up along with Darren Young and Phil McGuire in the absence of the suspended Scott Wilson and cup-tied Tam McManus and Stephen Glass.
Hibs boss John Collins had brought back most of his experienced men after making eight changes for Saturday's league draw with Aberdeen.
But Damon Gray retained his place ahead of Steven Fletcher after the young striker scored at Pittodrie.
And it was Hibs who grabbed the initiative from the start, Abdessalam Benjelloun firing straight at goalkeeper Dorus De Vries from 25 yards.
But Dunfermline started to force their way into the game and goalkeeper Andrew McNeil did well to turn a low Hammill drive wide after it took a deflection.
It was McNeil to the rescue again, blocking Jim McIntyre's header from a corner and, when McGuire's knee connected with the rebound, Lewis Stevenson headed off the line.
Scott Brown dominated the midfield and weaved his way through the defence before chipping over the advancing De Vries - only to watch as Greg Shields cleared off the line.
De Vries had to turn a 25-yard drive from Stevenson over the bar as Hibs applied the pressure again.
Chris Hogg (right) conceded the penalty to Dunfermline
And Benjelloun curled a drive over from the edge of the box.
Collins replaced the anonymous Gray with Fletcher at half-time, but it was Dunfermline who were the greater threat early in the second half.
Nine players on show were one caution away from missing the final and Dunfermline's Gary Mason fell foul of the two-booking rule after a late challenge on Steven Whittaker.
Jones headed wide of the Pars post following a corner and Fletcher again rose above the defence but fired over from eight yards.
A shot on the turn by Brown was half blocked by De Vries and McCunnie cleared off the line, while there were claims for a penalty when Sol Bamba clashed with Hibs substitute Dean Sheils.
But Dunfermline broke forward and Hammill was knocked down by Hogg after jinking into the box.
McIntyre lazily chipped the penalty kick into the centre of the net as McNeil dived to his right.
The Hibs goalkeeper prevented Mark Burchill scoring a second on the break with a fine save, but one goal was enough for the team sitting bottom of the SPL.
Dunfermline: De Vries, Shields, McGuire, Bamba, Muirhead, Young (Burchill 77), Mason, McCunnie, Hammill (Ross 88), O'Brien (Owen Morrison 70), McIntyre.
Subs Not Used: McKenzie, Daquin.
Booked: Mason, Hammill, McIntyre.
Goal: McIntyre 88 pen.
Hibernian: McNeil, Whittaker, Hogg, Jones, Murphy, Scott Brown, Beuzelin (Chisholm 74), Stevenson, Sproule (Shiels 67), Benjelloun, Gray (Fletcher 46).
Subs Not Used: Simon Brown, McCann.
Ref: C Thomson