Mansfield snapped a five-game losing streak after coming back to draw 1-1 with Rochdale.
Substitute Danny Johnson scored less than three minutes after entering the pitch to cancel out Danny Cashman’s 50th-minute opener.
The visitors had enjoyed the better of the limited first-half chances with Jake Beesley twice going close in the opening 25 minutes.
At the other end, Rochdale goalkeeper Joel Coleman comfortably saved a long-range Stephen McLaughlin with chances at a premium.
Mansfield had a chance to snatch the lead on the stroke of half-time but Rhys Oates was just unable to tap home a Jordan Bowery cross at the back post.
Dale threatened again at the start of the second half when Max Taylor headed a corner over from just three yards out three minutes after the restart.
However, they did not have to wait long to take the lead as Cashman fired Rochdale ahead after Matty Dunn took full advantage of a blunder by Kellan Gordon to pick him out.
Bowery curled wide before George Maris had a powerful shot blocked as Mansfield pushed for an equaliser.
And they got the response they were looking for when replacement Johnson slotted home from close range in the 73rd minute from Ollie Clarke’s cutback.
The hosts then almost snatched it at the end but Coleman made a great reaction save from Harry Charsley on the stroke of full-time.