Dan Biggar kicked six penalties to steer the Ospreys back from the brink of defeat as they overturned a 13 point deficit to beat Ulster 23-22 at the Liberty Stadium.
The axed Welsh outside half guided the Magners League champions to a much needed victory that keeps them in touch with the top four teams on a weekend when two of them slipped up away from home.
The Scarlets were pipped in Connacht and runaway leaders Munster were overturned in Treviso, so the Ospreys needed to make the most of the weekend by closing the gap on the front runners for the four Play-Offs places on the road to the second Magners League Grand Final on Saturday, 28 May.
The four points looked a long way off after Ian Humphreys had given Ulster a 13-0 lead with two penalties and then a penalty try which he also converted. In much the same way as they had blown away Cardiff Blues on their last visit to Wales, when they ran out 37-15 winners, Ulster scored at almost a point a minute in the opening quarter to create what looked like being a winning platform.
But after that bright opening the Ospreys scrum began to turn the screw and the penalties flowed as the Ospreys finally got their act together.
That allowed Biggar to prove he can still hit the mark with his goalkicking as he landed six out of eight attempts to punish the visitors. One of his penalties was a monster from 55 metres on the stroke of half-time that gave the home side the lead for the first time at 14-13.
As well as Biggar's three penalties the Ospreys also conjured up a corner try for ex-All Black flanker Marty Holah which owed much to the skill and vision of Ashley Beck, who threw a long, cut out pass to create the opening.
Two silly home indiscretions at the start of the second half allowed Pienaar, who took over at outside half from Humphreys when he left the field with a shoulder problem after 31 minutes, to show off his considerable goalkicking skills and Ulster suddenly found themselves five points clear.
But Biggar replied with three more penalties, two for scrum offences, and not even a third strike from Pienaar six minutes from time could claw back the deficit.
Scorers:Ospreys: Try: M Holah; Pens: D Biggar 6. Ulster: Penalty Try; Con: I Humphreys; Pens: R Pienaar 3, I Humphreys 2
When the Wales squad were asked to nominate individuals who played a big part in their early playing days, Wales and Dragons full back and wing Hallam Amos thought of his former Monmouth School rugby coach John Bevan.
Sam Cross and Luke Treharne have been named as co-captains of the Wales Sevens side as head coach Gareth Williams names his 12-man squad to play in the first leg of the HSBC World Series in Dubai next weekend.
Bedwas head coach Steve Law and players Nicky Griffiths and Alun Rees extol the virtues of the close knit club as they prepare to host third place RGC 1404 - who are one place head of them on the Principality Premiership points table - on Saturday.
Many of the Wales squad have said Diolch (thank you) to someone who played an important part in their early playing days by nominating them to be invited to the Wales v South Africa match. One person, Gowerton Comprehensive geography teacher Mr Dean Mason was nominated by two of his former pupils, Dan Biggar and Sam Davies.
The second WRU disability rugby pilot has been delivered, this time in Caerphilly schools, culminating in a festival at the Caerphilly Centre of Sporting Excellence, Ystrad Mynach tomorrow. Plans are in place to set up a Disability Rugby Club in Newbridge to provide long-term playing opportunities.
WRU TV: Hear from inside the Wales camp as Neil Jenkins discusses this weekend's clash with South Africa and how the squad are looking to put in a strong performance to round of the 2016 Under Armour Series