Centre-half Will Evans scored an equaliser and saved a penalty for 10 man Chesterfield in a wild stoppage time at the Proact.
The defender’s wonderful header made it 3-3 as the Spireites somehow clawed their back from a 3-0 first half deficit to seemingly snatch a point against Ebbsfleet.
But a moment of madness from keeper Callum Burton almost cost Town dearly - his retalitory punch on Michael Cheek earning him a red card and handing Ebbsfleet a penalty to win it.
Up stepped Evans, however, to beat away Cheek’s spot-kick and ensure John Pemberton ended his three-game caretaker spell undefeated.
The game will certainly give the incoming John Sheridan plenty to think about, with a dreadful first half performance followed by a drastic improvement.
The opening minutes were a bit of a non event, Chesterfield doing very little with possession in good areas.
Ebbsfleet were handed a great chance to counter attack when Haydn Hollis played a sloppy pass in midfield and it was the centre-half who halted the move, albeit with a foul on Cody McDonald that brought a yellow card.
A minute later Ebbsfleet stormed down the left through Bagasan Graham and McDonald headed over from a dangerous cross.
There were better moments for Town on either flank before the 20 minute mark, Lee Shaw threatening on the right before Jerome Binnom-Williams played a one-two with Marc-Antoine Fortune and saw his low cross cut out.
But a neat one-two was all it took to completely unlock the home defence and Michael Cheek went clean through on goal, forcing Callum Burton to pull him down.
Burton was yellow carded, a penalty awarded and Cheek himself put Fleet ahead with a cool finish.
At the other end, Shaw’s determination to stay on his feet perhaps cost his side a spot-kick, running onto a Jonathan Smith pass and electing to remain upright after drawing contact from keeper Nathan Ashmore, before losing the ball.
Having contrived to give the ball away sloppily on numerous occasions in the first half, Town were punished five minutes before the break, Ebrima Adams getting hold and playing it up to McDonald, who turned Hollis inside out and finished well past Burton.
Another penalty shout came and went, this time for Town replacement Tom Denton, before Ebbsfleet went up the left all too easily and Bagasan Graham drilled in number three.
Both sides had good chances in the first five minutes of the second half, McDonald beating Will Evans and shooting against Burton’s legs, while at the other end Shaw failed to take advantage when Ashmore dropped a routine catch.
Chesterfield had a decent spell, at least in terms of territory, if not in terms of quality in possession and Ebbsfleet perhaps were lulled into a false sense of security, because they stood and watched Denton run in unmarked to head home a Brad Barry cross.
A second very nearly arrived when Fortune flicked on a corner and Hollis tried to bundle it home at the back post, Ashmore clawing it out.
Burton had to be sharp to palm out Ebrima Adams’ shot, Ebbsfleet remaining a threat with the game so open.
With just seven minutes left Town pulled another one back, Burton’s long ball forward flicked on by Denton, controlled and fired under Ashmore by Fortune.
Ashmore twice got involved with fans behind the goal, seeing yellow for time wasting as the game entered time added on.
He was picking the ball out of the net shortly after, Kyel Reid’s cross from the left met by Evans who guided his header in off the post to spark a mini pitch invasion.
All the momentum was with the hosts, but as Burton attempted to roll the ball out he was impeded by Cheek and lashed out, giving referee Welch no choice but to send him off.
Evans donned the gloves and stunned the entire stadium with his penalty save in what was the final act of a crazy game.
CHESTERFIELD: Burton, Barry (Reid 74), Binnom-Williams, Evans, Hollis, Sharman (Denton 35) Smith, C. Weston, Beestin (Weir 46), Shaw, Fortune. Subs not used: Anyon, Rawson.
EBBSFLEET: Ashmore, Wilson, Graham (M. Weston 60), King, Magri, Bush, Adams (Whiteley 83), Drury, Cheek, McDonald (Kedwell 70). Subs not used: Rance, Moncor.
GOALCORERS: Denton 64, Fortune 83, Evans 90; Cheek 22 (pen), McDonald 41, Graham 45.
YELLOWS: Hollis 14, Burton 21, Smith 43; Ashmore 90.
REDS: Burton 90.
REFEREE: Rebecca Welch. Assistants: Michael D’Aguilar, Scott Chalkley.
ATTENDANCE: 4,123 (177 away).