Nick Macleod, who recently made his senior debut against Cambridge University, kicked the only points of the first-half with a penalty that gave Cardiff the lead at 3-0.
Llanelli came back into the match when acting captain Aled Gravell scored a try and he was soon followed over the line by prop forward Phil John with fly half Phil Fisher kicking a penalty goal.
At 13-3, Cardiff retaliated with a try by wing Geraint Williams and a second penalty by Macleod, but the latter’s conversion attempt that would have provided the equalising points went wide.
Llanelli turned out their Academy 17-year-olds against Bath at Stradey Park and pulled off an excellent 18-0 win.
Wing Dafydd Evans ran the first try in from 50 metres and full back Ricky Williams placed a 30-metre penalty to lead 8-0 at the break.
In the second spell, centre Aled Thomas raced in for the second Scarlet try and a smart pass by fly half Roger Davies put Williams away for the final score.
Earlier, Cardiff’s under-21’s had scored a resounding 41-15 win at Swansea, to avenge their 31-29 loss at home in the first meeting. It was one of the best Cardiff performances that included tries by full back Owain Ashman, scrum half Scott Heddington, lock Luke Tait, wings Elgan Jones and Geraint Williams and centre Liam Roberts.
Nick Macleod placed four conversions and a penalty, but Swansea had led 15-13 at half-time and then lost lock Bill Brereton with a broken ankle. Prop Steve Tremlett and Brereton scored their tries with fly half Gareth James adding a penalty and conversion.