Having gone four Barclays Premier League matches without a goal, Villa looked certain to draw another blank as they laboured for three quarters of a low-quality encounter against a Cardiff side showing little of the fight that saw them defeat Swansea last week.
But Bacuna laid the foundation for their 2-0 win with a precision free-kick in the 76th minute, having won the decision himself following a foul by Gary Medel.
That opened things up enough for Kozak to double the lead eight minutes later, heading home after substitute Matt Lowton had nodded the ball across the face of goal.
Prior to that late action it had been an unedifying affair all round, with Villa booed off by their own fans at the interval.
The hosts began with plenty of attacking intent, Kozak's header drawing a good save from David Marshall after just a minute - though an offside flag would have cancelled it out regardless.
Marshall was less assured when Karim El Ahmadi tested him from 25 yards, palming the ball back into the danger in front of goal with Christian Benteke sniffing around.
Luckily for the visitors Steven Caulker was a fraction quicker off the mark than the Belgian and cleared the danger.
Caulker was also the unlikely originator of Cardiff's first real attack, carrying the ball towards the edge of the Villa area before chipping a pass towards Aron Gunnarsson.
Villa might have conceded had Peter Odemwingie got a clean connection with his attempted volley but when it bobbled away from the Nigerian, Ron Vlaar slid in to avert the danger.
There were still only 10 minutes gone Medel's floated free-kick drew Kozak into a defensive header that wrong-footed Brad Guzan and flashed across the face of his own goal.
Benteke, still looking for the inspiration that was ever-present last season, had one further sight of goal but shot wide having ignored Aleksandar Tonev's intelligent run.
The next half-hour was little more than a non-event, Cardiff having marginally the better of things but producing nothing clearer than a Craig Bellamy free-kick that Guzan was able to catch with minimal fuss.
Odemwingie gave hints that he may have the skill to create a breakthrough without ever actually doing so, while Villa's efforts were stifled too often by sloppy passing - Yacouba Sylla too often the guilty party in that respect.
When the sides went in for the break there was an audible, though hardly deafening, chorus of boos from the home support.
Nathan Baker's body check on Odemwingie 25 yards out gave Cardiff the first chance to spark the game into life and former Villa man Peter Whittingham stood over the free-kick.
He whipped the ball across the area but none of his team-mates were able to get a boot to it.
Villa countered and went closer than ever to an opening goal as Bacuna's cross found Kozak at the far post.
His header looked to be on target but Marshall did enough to keep it out.
Malky Mackay had seen enough of Odemwingie after 55 minutes and sent on Fraizer Campbell, whose high-energy style at least provided a sharp contrast to the man he had replaced.
With 62 minutes gone Ashley Westwood's first-time shot - taken after Benteke's pass had ricocheted off Kevin Theophile-Catherine - briefly looked as if it might find the top corner but ended up a yard high and wide.
Benteke had two headers in the space of 10 minutes from positions he would typically fancy but on each occasion his radar was off and he failed to hit the target.
Bacuna, moved into midfield as part of a tactical reshuffle, rescued the game from stalemate.
He powered into the Cardiff half and was heading towards the penalty box when Medel's cynical foul stopped him his tracks.
But that merely delayed the danger and Bacuna curled the resulting free-kick round the wall, leaving Marshall flat-footed as the ball hit the net.
Villa made the points safe when Kozak claimed his second goal for the club, heading home after a period of untidy defending by the Bluebirds.
Tonev's initial cross was poorly cleared by Theophile-Catherine, allowing Lowton to head back towards Kozak, who applied the finishing touch from six yards.
Source: PA
Source: PA