Burnley suffered only their second defeat of the season despite Ade Akinbiyi's header at Ninian Park.
Half time substitute Akinbiyi scored his third goal of the season early into the second half to cancel out Joe Ledley's first half header.
But Paul Parry struck a fine winner just minutes later to earn the Bluebirds the spoils.
David Unsworth made only his second league start for the Clarets in a midfield holding role.
Andy Gray led the line in front of a five-man unit, with Kyle Lafferty and Robbie Blake in wider roles and both looking to support the Scotland international at every opportunity.
There was a late change for Cardiff, when Stephen McPhail was injured in the warm up and was replaced by former Burnley loanee Peter Whittingham.
The opening four minutes were played exclusively in the Clarets half as City looked to start with a bang.
But Robbie Blake soon settled the Clarets with a sublime piece of hold up play before sliding in Gray, who was just offside as he looked to sneak behind the last man.
Thirteen minutes in, Lafferty's broke down the right and cleverly switched play to Blake, who typically found space for a drive that was inches too high.
The Burnley defence were coping admirably with City's feared front pairing of Robbie Fowler and Jimmy Floyd Hasselbaink.
But in the 25th minute their very presence allowed Whittingham to steal in at the far post and come within a bootlace of converting Kevin McNaughton's dangerous ball across the six-yard box.
And in the 38th minute, the Clarets fell behind to the simplest of goals. Substitute Darren Purse crossed from the right and Joe Ledley rose totally unchallenged to head past the exposed Kiraly.
Jubilant Ledley thought he had made it two 60 seconds later with a wicked, dipping drive from distance that Kiraly magnificently turned over at full stretch.
Burnley responded and Blake's inviting ball into the Cardiff box deserved better as the half petered out.
HT: Cardiff 1 Burnley 0
Half time changes were what Steve Cotterill had in mind and the Clarets boss made a treble substitution to try to find a way back into the game.
Akinbiyi, Wade Elliott and McCann were all introduced for Unsworth, Mahon and Lafferty, as the side reverted to a 4-4-2 formation, with Blake left and Elliott right.
And the move paid instant dividends as Burnley were level within six minutes.
Blake was the architect with a clever back heel to release Stephen Jordan, and when the former Manchester City defender swept the ball across, a deflection at the near post carried the ball to Akinbiyi, who nonchalantly headed back across goal and past Oakes.
Gray, boosted by now having a strike partner to feed off, was close to turning the game on its head moments later, expertly controlling a dropping ball and firing in a right-foot shot that Oakes did well to parry.
But cruelly, City grabbed the lead again within four minutes of the equaliser when Parry cut in from the right and found the bottom corner from the edge of the box.
Burnley now had it all to do again and with a quarter of an hour remaining Parry brought another fine save from Kiraly after this time opting to take on Jordan and shoot with his right foot.
Hasselbaink conned referee Andy Penn to award a free kick nine minutes from time on the edge of the Clarets box, but Kiraly was equal to the former Premiership striker's thunderous drive.
And despite forcing the hosts onto the back foot in the closing moments, Burnley just could not conjure up the chance to equalise for a second time.
Burnley: Kiraly, Jordan, Caldwell, Carlisle, Alexander, Unsworth (Elliott 46), Mahon (McCann 46), Spicer, Lafferty (Akinbiyi 46), Gray, Blake.
Subs: Harley, Jensen.
Booked; Spicer 72, Caldwell 81
Cardiff: Oakes, McNaughton, Capaldi, Rae, Loovens (Purse 23), Fowler (Thompson 66), Whittingham, Parry, Johnson, Ledley, Hasselbaink (Ramsey 86), Ramsey.
Subs: Forde, Gunter
Ref: A Penn
Att: 12,914


















