Two late goals saw them reduce the gap to safety to two points, with two matches left to play.
At one stage in the second half, that gap was seven and would have meant relegation but a stunning finish to the game puts everything back in the U's own hands.
Despite getting forward at every opportunity, the U's couldn't find the net in the first half - but nor could the hosts and the game was goalless at the break.
The second half was a different mater, with the U's going ahead, going behind and then scoring twice in two minutes to win.
When Fleetwood went 2-1 ahead, the U's League One days were numbered, but Massey and Porter's late goals ensured the U's survival hopes were intact.
The game started with both teams looking to attack and it was the U’s who had the first couple of efforts at goal.
First, Gavin Massey picked up the ball and shot from distance and then his cross was just behind Chris Porter and the U’s centre forward couldn’t slow down in time to get a shot away.
At the other end, Proctor was denied by a great block from Bongani Khumalo after creating a chance for himself from a long diagonal ball by Pond.
A break from the home side resulted in a ball coming in from the right and Procter might have done better with his effort at the far post but could only divert it to a U’s defender to clear.
Jacob Murphy was next to get a sight of goal, but his strike was into the sidenetting of Maxwell’s goal.
That chance came on seventeen minutes and the teams continued to trade scoring opportunities, with Tom Eastman clearing off the line two minutes later from a back post header.
A great chance came the U’s way halfway through the half as Richard Brindley got forward on the right hand side.
His low cross was as good as Porter’s near post run but the side foot effort flew narrowly wide of the upright.
Sam Walker made an awkward save on twenty six minutes, scooping a free kick away to safety as the ball bounced just in front of him.
George Moncur maybe could have got a shot away after good work by Murphy and Briggs down the left but eventually found Fox, whose shot was blocked.
The U’s were denied an opener by a superb save by Maxwell on thirty five minutes, with Massey holding his head after his goalbound volley was saved.
A minute later, Maxwell was again the home hero, saving low from Murphy as the U’s finished the first half on the attack.
The second half got off to a perfect start for the U’s and unsurprisingly, it was on the flanks that they got some joy.
Jacob Murphy beat three Fleetwood defenders before looking up and cleverly pulling the ball back for the onrushing George Moncur.
A firm side foot was the perfect option and the ball rocketed through Maxwell’s legs and into the net right in front of the celebrating U’s fans.
In the early stages of the half, Murphy was causing Forbes all sorts of problems and it was no surprise to see the young full back replaced.
The change worked for the hosts and it was their dangerman Proctor who got them back in the game on sixty four minutes.
Richard Brindley slipped at the vital moment and despite the U’s repelling the initial effort, Proctor was on hand to score on the turn from the edge of the six yard box.
It went from bad to worse for the U’s nine minutes later, as substitute Ball went through and sidefooted high into the net past the diving Walker.
It had looked like Ball had fouled Bongani Khumalo in the build-up to the goal but the referee waved away the U’s appeals and at that stage, relegation looked on the cards.
It fact, it was a reality as results elsewhere saw a two point gap to safety reach an unassailable seven with only two U’s matches to go.
With six minutes remaining, the U’s got a lifeline, as they equalised when Gavin Massey’s cross ended up in the back of the home net.
It wasn’t clear whether young sub Macauley Bonne had got a touch but the important thing was that as things stood, the U’s survival hopes were just about still in intact.
Two minutes later, and the U’s were in front once again.
Dion Sembie-Ferris latched onto a great through ball and was upended just as he got into the penalty area.
The referee pointed to the spot and it was up to Chris Porter to give the U’s the points.
He duly obliged, driving his spot kick low past Maxwell and once again reducing the gap to safety to two points.
A few people on the pitch delayed the restart and the fourth official put up the board with six minutes showing as added on time.
The U’s comfortably saw out that time and kept their survival hopes in their own hands with two games to play.
Both come at home and two wins at home against Swindon and Preston ensure that the U’s are playing League One football next season.