Alex defender Harry Davis owes a big debt of gratitude to his team-mate after his own goal looked set to deny Crewe a shot at League One, although Alex's place in the top seven was made safe by local rivals Port Vale's victory over Oxford.
The Railwaymen looked to have settled any early nerves in the fourth minute when AJ Leitch-Smith tapped home from six yards after Jamie Young had saved a Byron Moore effort.
However, mid-table Aldershot sprang into life thanks to Davis' own goal from a long Ben Herd free-kick after 30 minutes, and substitute Mark Molesley stunned Crewe in the 45th minute when he picked up a loose ball and curled home from 20 yards.
Aldershot should have put the game beyond doubt in the 54th minute when Adam Mekki rounded Steve Phillips but unbelievably fired wide of an open goal.
And they were made to pay as Murphy's 20-yard volley in the 75th minute set up a play-off clash with Southend, the last team to beat Alex 16 games ago.