Cheltenham extended their unbeaten run to six matches as they stunned promotion-seeking Mansfield.
Karl Henry hit a first-half rocket from 30 yards, before Damian Spencer's goal on the hour put the Robins in charge.
Mansfield hit back through Iyseden Christie only for Paul Brayson to restore Cheltenham's two-goal cushion.
Wayne Corden took advantage of some poor Cheltenham defending to make it 3-2, but Kay Odejayi's injury-time strike sealed the win.
Cheltenham: Higgs, Griffin, Michael Duff, Brough, Victory, Devaney, Henry, Finnigan, McCann, Spencer, Brayson. Subs: Book, Forsyth, Bird, Odejayi, Gill.
Mansfield: Pilkington, Buxton, Day, Artell, Vaughan, Disley, Lawrence, Dimech, Corden, Mendes, Christie. Subs: Larkin, Pacquette, Hassell, White, Williamson.
Referee: K Friend (Leicestershire)