Town struck late for the third successive home game to grab the points thanks to Brett Pitman’s close range header.
Blues dominated the game but looked likely to have to settle for a point after going behind after just 12 seconds.
Souleymane Doukara found the net from kick-off to record the quickest goal in the Football League this season but Leeds rarely troubled after that.
Luke Chambers got Blues back on level terms five minutes into the second-half and chances came and went until Pitman got on the end of Ryan Fraser’s cross to end Leeds’ eight match unbeaten League run and keep Town in the top six.
Blues got off to the worst possible start when Doukara latched on to a mistake outside Town’s box and fired past Dean Gerken before some of the 19,000 crowd had taken their seats.
Daryl Murphy responded with a jinking run and then shot that Marco Silvestri pushed away to safety. Then Chambers claimed a penalty when he went down as he tried to divert Christophe Berra’s header goalwards.
Gerken was in the right place to gather after Mustapha Carayol’s cross had been diverted towards goal by Tommy Smith in a frantic opening to the game.
Gerken was forced into action again when Carayol’s cross was deflected towards the top corner by a blue shirt, then at the other end Freddie Sears warmed Silvestri’s gloves with a 20 yarder.
Kevin Bru then saw his cross beat everyone when just a touch would have put the ball in the net.
Chambers headed over from Bru’s corner as Town carried a threat from corners, Bru then smashed a right footer held by Silvestri diving to his left.
Jonathan Douglas had Sears’ cross taken off his head as he looked to pounce, then Murphy showed a great touch and awareness to spin and test Silvestri with a left foot strike from distance.
Chambers almost forced his way through after neat interplay between Ryan Fraser and Bru, Silvestri then doing well to divert Fraser’s effort to safety and safeguard the visitors’ lead to the break.
Sears fired over as Town started the second-half in positive fashion and on 50 minutes, Blues were level, Chambers heading in Fraser’s cross.
Silvestri gathered from Fraser’s cross as Town forced Leeds back, Chambers denied a second as Liam Cooper blocked his effort, then Cole Skuse was inches away with a curler.
Berra was denied by Silvestri from Bru’s cross as Town looked the far more likely to find a second goal, though Jonas Knudsen had to show a cool head to chest Stuart Dallas’ cross into Gerken’s hands.
Bru sent a wicked cross that drifted just past Leeds’ far post before Town made a first change 15 minutes from time with Pitman on for Murphy.
Pitman was a boot lace away from getting on the end of Fraser’s cross with Silvestri out of the game and the goal open but the two combined to find the winner in added on time with Pitman heading in.