Roger Johnson and Michael Chopra struck to lift Cardiff City above Preston North End and end the visitors' five-game unbeaten run.
The Bluebirds pair netted in either half as they leapfrogged their promotion rivals to record a deserved win.
Johnson set the Welsh side on their way with a towering first-half header to break the deadlock and substitute Chopra made sure of the win with a late penalty.
A lively start almost resulted in both sides opening the scoring in the opening minutes.
Andy Lonergan's weak clearance almost saw Jay Bothroyd's first-time shot embarrass the visiting goalkeeper.
Then moments later Richard Chaplow was inches away from sliding in Neil Mellor's inviting cross into the danger zone.
An error-strewn first half saw finally sparked into life when defender Johnson headed home in the 42nd minute.
After Paul McKenna was penalised for handball, the Bluebirds defender rose highest to nod in Wayne Routledge's free-kick for his second goal of the season.
It was just what the game needed as a tight and largely error-strewn Championship clash opened up after the break.
Cardiff had visibly grown in confidence with their zippy interchange causing Preston problems.
Paul Parry fired in a cross which evaded everyone while Joe Ledley was off-target when well placed.
But the Lilywhites have been scoring goals for fun of late and engineered the game's best move which could have seen them level matters in the 54th minute.
A sweeping move saw Chris Brown back heel into Ross Wallace's path and the on-loan Scot forced a low save from the largely redundant Peter Enckelman.
It prompted Cardiff to up the tempo which almost saw Parry create a second goal twice in successive minutes.
The winger's cross was first headed firmly on to the post by Bothroyd and Gavin
Rae's low shot was then kept out by Lonergan.
But Chopra would have his revenge from the penalty spot in the 76th minute. Bothroyd was tripped by Youl Mawene for a stonewall penalty and Chopra sent Lonergan the wrong way to seal the win.