Cardiff kept their URC play-off hopes very much alive and clinched the Welsh Shield with a six-try bonus point victory in this Judgement Day opener at the Principality Stadium.
They had the four-try bonus in the bag before the break with flanker Alex Mann and wing Gabriel Hamer-Webb both crossing twice to establish a 22-7 half-time lead.
The Ospreys fought back to set up a grandstand finish, but Matt Sherratt’s team sealed the victory with two late tries as Player of the Match Hamer-Webb completed his hat-trick.
It’s a triumph which takes them up to sixth in the league table and level on points with fifth-placed Benetton.
It also sets up a real humdinger of a clash with play-off rivals Munster at the Arms Park next Friday night.
When the game got underway, it was actually the Ospreys who opened the scoring with a converted try from centre Keiran Williams on 11 minutes.
They had been handed a one-man advantage by Teddy Williams being yellow carded for head contact in a tackle on Dan Edwards and they capitalised with Williams stepping inside to touch down after a powerful carry from Wales captain Jac Morgan.
But it was Cardiff who were to do all the scoring for the rest of the first half after that as they increasingly took control.
Despite being down to 14 men, they soon drew level as they were rewarded for their ambition. Rejecting a simple kick at goal, they opted for a tap penalty instead and it paid off as blindside Mann spun over following a strong surge from prop Corey Domachowski.
Once restored to their full complement, they struck again four minutes later to take the lead.
After Josh Adams – making his 50th appearance for the club – won a jackal penalty, they kicked to the corner where Williams marked his return to the fray by claiming the resulting lineout.
Following a maul rumble and a succession of forward carries, the ball was moved left with Cam Winnett throwing out a huge pass to Hamer-Webb who cut between Jack Walsh and Dan Kasende to score.
It wasn’t long before the winger had his second in the bag.
A cleverly delayed pass from Callum Sheedy sent Ben Donnell galloping across half way with the second row then feeding Hamer-Webb who managed to hold on to the ball with a little juggle, fend off one defender and get back to his feet to score after being ankle tapped by Walsh.
Cardiff were now flying and secured the four-try bonus five minutes before the break.
This time Hamer-Webb was involved in the build-up, chipping over the top for Johan Mulder to win the race to the ball and then stepping in as scrum-half in place of the prone South African.
It was then all about the clinical finish and that was delivered as Ben Thomas put in a cross kick which Mann reached above his head to collect before dabbing down in the right corner.
The Ospreys’ plight worsened when No 8 Morgan Morse was sin-binned following an accumulation of penalties.
It looked as though Cardiff had rubbed salt in the wounds when Morse’s opposite number Taulupe Faletau burst through to the line, only for the try to be disallowed for a croc roll by Mann in the build up.
But, nevertheless, they went in at half-time with a commanding 22-7 lead.
When the action resumed, it was soon their turn to be down a player again as Morse’s return was followed by a yellow for Mann for a late no-arms hit on Reuben Morgan-Williams.
They held firm for almost the whole of the sin bin period through some defiant defence, but were eventually breached when replacement lock Will Spencer went over after sustained pressure.
Mann’s eventful game continued once he returned as he narrowly missed out on completing his hat-trick when he was held up over the line, while it was then the turn of replacement flanker Thomas Young to be denied just short of the whitewash.
Three minutes from time, Ospreys scrum-half Kieran Hardy squirmed through to score straight after a yellow card for centre Harri Millard for a deliberate knock-on.
Dan Edwards converted to cut the deficit to three points and set up a nerve jangling finish.
But Cardiff sealed a huge victory with two scores in the final couple of minutes.
First they earned a penalty try through a powerful lineout maul drive and then Hamer-Webb completed his hat-trick as he pocketed a grubber kick from Young and raced away just ahead of being named Player of the Match.