Andy Kirk glanced in a late header as Dunfermline staged a thrilling comeback to earn a point at St Mirren.
Nigel Hasselbaink shot the Buddies into an early lead, only for Jordan McMillan to curl in a lovely equaliser.
Steven Thompson crashed in two powerful headers either side of half time before David Graham pulled one back.
Thompson found the top corner with a strike for his hat-trick before Liam Buchanan did the same from long range and Kirk nodded in the leveller.
A quite incredible game leaves Dunfermline six points behind second bottom Hibernian, who play on Sunday, as they battle to avoid relegation from the Scottish Premier League.
And, despite their striker bagging an impressive hat-trick and twice leading by two goals, St Mirren were unable to improve their record of just one win in 2012.
Pars manager Jim Jefferies had declared victory a must and both sides were commited to attack right from the off, although some sloppy defending contributed to the high goals-tally.
Hasselbaink was left all alone as Paul McGowan picked him out with a pass for the opening goal on four minutes. The Dutchman was then able to turn inside Alex Keddie and slotted the ball past Chris Smith.
Kyle Hutton twice threatened for the visitors but Lee Mair's sliding block stopped the first effort and the on-loan Rangers midfielder then shot wide from 15 yards.
Dunfermline kept pressing and Graham hit the inside of the post with a powerful drive from 20 yards before Keddie headed wide.
The deserved equaliser came in the 24th minute when right-back McMillan cut inside and fired an excellent left-footed effort into the far corner of the net from 25 yards.
McGowan met Graham Carey's cross inside the six-yard box and his header bounced down off the turf and against the crossbar, while Thompson could not net the rebound.
Kenny McLean, Carey and McGowan threatened from long range as Saints regained the upper hand and Thompson headed home from six yards after a wonderful cross from Carey.
Early in the second half, Thompson delivered another blow when he beat Andy Dowie to Dougie Imrie's right-wing cross and headed into the roof of the net.
But Graham pulled one back with 56 minutes gone with a cool finish following a smart one-two with Hardie.
Dunfermline pushed on again but Thompson completed his treble when David van Zanten dispossessed Joe Cardle deep inside the Pars half before laying the ball off to the striker to fire into the top corner from 15 yards.
The visitors refused to let their heads go down and the impressive Hutton won the ball in the centre circle to allow Graham the chance to send Buchanan free.
The pass and touch appeared to take the forward too wide but he unleashed a powerful strike that swerved out of Craig Samson's reach and into the near top corner.
The small band of travelling fans went wild when Andy Kirk managed to glance in a header from close range and the substitute fashioned two more late chances without hitting the target.
St Mirren manager Danny Lennon: "As a neutral watching that would have been absolutely fantastic.
"It was a thoroughly entertaining game with good goals and end-to-end action.
"But as St Mirren manager I'm absolutely livid not to take maximum points after having the game sewn up on a number of occasions.
"We didn't keep possession and do the right things. I'm very, very angry because it was a wonderful opportunity missed."
Dunfermline manager Jim Jefferies: "You could see the way the team was set up, we played virtually four attackers because it was a game we were desperate to win.
"For the last 10 minutes I have gone 3-4-3. We have thrown Kirk on and just went for it.
"After the goal he has a chance and if he hits the target we are winning the game.
"At 3-1 down and 4-2 down in the position we are in you would be delighted with the response of the players. I am over the moon with their response to get something.
"It was a win we were wanting but if Hibs lose tomorrow that's a point closer.
"It's another game away and it makes it a wee bit tougher, but it doesn't mean it's impossible."