Dorking came from two goals down to beat Altrincham to move six points clear of the Vanarama National League relegation zone.
It was a fifth win in six league games for Marc White’s side as Jason Prior struck the decider in a 3-2 victory.
Regan Linney and Maximillian Oyedele had the visitors two goals up inside the opening eight minutes but they were eventually pegged back.
James Muitt halved the arrears before the interval as goals from Harry Ottaway and Prior completed a fine comeback.