Leeds were made to sweat for their three points despite playing against 10 men for most of the game at Crewe. The home side had defender Billy Jones red-carded for verbally abusing the female assistant referee.
And the 16th minute dismissal proved to be a turning point after Crewe had looked lively early on. Jones had tangled with Robert Snodgrass and was initially only going to be booked for a foul on the winger.
But he was soon in heavy water and Crewe soon found themselves with a mountain to climb. Neil Kilkenny drove in the opening goal in the 27th minute after a Fabian Delph effort was blocked from a corner.
Within five minutes Simon Grayson's side were running away with it as Snodgrass's chip from the by-line tee'd up Luciano Becchio for a close-range header for the second and then Snodgrass broke free to bury the third under the home keeper John Ruddy.
Crewe also lost midfielder Steven Schumacher who was stretchered off before half-time.
Crewe's misfortune with the officials continued at the start of the second half when Richard Naylor, who had already been booked, escaped dismissal after hauling down substitute Byron Moore.
Crewe were fuming and it spurred them on and back into contention when Julien Baudet headed home Gylfi Sigurdsson's corner on the hour mark.
And Leeds' control on the game was completely lost when they conceded again in the 73rd minute, Danny Woodards shot was blocked, Tom Pope stooped to head home the rebound.
Crewe piled on the pressure in the closing minutes but were vulnerable to the break and Ruddy saved from substitute Bradley Johnson and Snodgrass as Leeds looked to kill the game.
They could have ended up having to settle for an embarrassing point had keeper Casper Ankergren not turned Sigurdsson's free-kick around the post.