Alex Fisher’s last-minute goal condemned Morecambe to their second defeat of the season.
As with the Shrimps’ first loss at Tranmere Rovers, Jim Bentley’s side looked set for a point only to see it slip away with time almost up.
Fisher was the hero for the hosts, his close-range header after a near post flick on from Liam Marsden’s long throw knocking the Shrimps out of the top three as they dropped two places to fourth in League 2.
Mansfield dominated the game for long periods and should have taken the lead in the 10th minute but Raki Bingham blazed over the bar from close range after Barry Roche had reacted sharply to get down low to his right to save a sweetly struck volley from Matt Rhead.
Seven minutes later the home side threatened again when Roche’s weak clearance found Lee Beevers 25 yards from goal and his audacious lob sailed inches over the Morecambe bar.
The Shrimps created their first chance on 27 minutes when Aaron McGowan volleyed smartly towards goal forcing Stags’ stopper Dimitar Evtimov into a flying save.
From the resulting corner Padraig Amond looped a header against the cross bar with Mark Hughes bundling the loose ball only to be adjudged offside.
The second half followed a similar pattern with the Shrimps on the back foot for long periods.
Roche had to be at his best to save from another excellent Rhead shot from distance and Bingham forced the Shrimps’ keeper into a decent save with his feet on 77 minutes.
The Shrimps looked to step up the pace in the final stages of the game but were undone in the last minute when they failed to deal with the ball into the box and Fisher earned the home side the three points.
Mansfield: Evtimov, Sutton, Riley, Tafazolli, Marsden, Murray, Clements, Beavers, Bell (Fisher 74), Rhead (Palmer 81), Bingham. Subs not used: Studer, McGuire, Thomas, Taylor.
Morecambe: Roche, Parrish, Hughes (capt), Edwards, McGowan, Kenyon, Drummond, Fleming, Widdowson, Amond (Mullin 55), Sampson (Ellison 55). Subs not used: Arestidou, Williams, Goodall, Wright.
Booked: Hughes, Mullin.
Attendance: 2,185 (68 away).
Referee: S Martin.