Kieffer Moore's late double saw Cardiff fight back to earn a desperately-needed 2-1 win at home to Huddersfield.
Kieffer heads the winning goal
The Wales international headed home 16 minutes from time to cancel out Danel Sinani's first-half opener for the visitors and then crashed in a stoppage-time winner to end the Bluebirds' 10-game winless streak.
Moore's goals kept struggling Cardiff out of the bottom three and denied Huddersfield a place in the top-seven and meant Cardiff caretaker manager Steve Morison celebrated a first win in what is likely to be his final match in charge.
Cardiff still started sluggishly and they were caught cold after a lengthy stoppage for Huddersfield captain Jonathan Hogg to receive treatment.
He was forced off in the ninth minute and the visitors broke the deadlock three minutes later.
Sinani raced on to an under-hit backpass from Mark McGuinness and outmuscled Curtis Nelson before slipping the ball under Alex Smithies and in off the post for his first goal for the club.
Cardiff could not muster much of a response despite the efforts of Moore, who was sporting a blue bandage after a nasty clash of heads with Huddersfield defender Tom Lees.
The game finally sparked into life just before half-time with the hosts almost levelling on 38 minutes when Perry Ng's cross from the right was nodded back across goal by Moore and headed wide by Joe Ralls, who also saw a snap-shot hooked over by Sorba Thomas in first-half stoppage time.
But it was the visitors who ended the half the strongest. Former Cardiff front man Danny Ward played in Sinani and the Norwich loanee side-footed effort across goal was a foot wide of Smithies' far post.
Duane Holmes then played a clever disguise pass to Harry Toffolo to square the ball across the six-yard box but Ward could not get a proper connection with the goal gaping.
Substitute Josh Koroma also saw a golden chance smothered at close range by Smithies to keep Cardiff in the match.
Rain and swirling wind made for tough conditions after the break with both sides restricted to long-range strikes in the opening stages.
Ward fired over from distance for Huddersfield before Moore totally miscued a curling effort at the other end.
Smithies came to Cardiff's rescue once again on 64 minutes when he diverted a Levi Colwill header onto the post from point-blank range.
And the visitors hit the woodwork again three minutes later when Ward took advantage of a mistake by Aden Flint, flicking the ball over Smithies but against the upright.
And Huddersfield were made to regret those spurned opportunities.
Moore was rewarded for his battling display, heading in his first from a Ralls cross to level the match on 74 minutes and then repeating the trick from substitute Isaak Davies's centre at the death.
Cardiff City: Smithies, Ng, McGuinness (Colwill 70’), Nelson, Flint, Giles, Pack, Ralls, Bacuna (Vaulks 86’), Harris (Davies 60’), Moore.
Subs not used: Phillips, Morrison, Brown, Zimba.
Huddersfield Town: Nicholls, Pearson, Lees, Colwill, Toffolo, Hogg (High 9’), O’Brien, Thomas, Holmes (Koroma 45+1’), Sinani, Ward (Campbell 77’).
Subs not used: Bilokapic, Turton, Sarr, Aarons.