Wales were under pressure for long periods of the match but an interception try from Ospreys centre Ashley Beck gave the home side a scarcely deserved lead at the break.
Samoa could well have been out of sight had George Pisi not missed a number of shots at goal and although the boot of Leigh Halfpenny kept Wales in touch in a see-saw second half, further tries from Pisi and Johnny Leota gave the visitors a deserved victory and their fourth in all matches against Wales.
There was more bad news for Wales as Dan Biggar went off injured with a serious looking shoulder injury after being smashed by Samoan no.8 Tai Tu'ifua, albeit legally.
In the wake of the Argentina defeat, under-fire interim boss Rob Howley made sweeping changes, bringing in Justin Tipuric for Sam Warburton, recalling Mike Phillips at scrum-half and selecting Biggar at fly-half in place of Rhys Priestland. Back came Jamie Roberts in the centre alongside Ospreys centre Beck, making his first start at the Millennium Stadium in the famous red jersey.
Despite the wholesale changes, Samoa came out of the blocks quickly and stunned the home side with a try within the opening minute. Tai Tuifua burst through the middle, brushing off some non-existent tackling to suck in the Welsh defence and create space out wide for Fa’atoina Autagavaia to score in the corner. Tusi Pisi added the extras and Wales were 7-0 down in a heartbeat.
Samoa continued to dominate the early exchanges, forcing Wales into further errors. And Pisi should have further punished them with George North penalised for going in off his feet.
Having weathered the early storm, Halfpenny finally got the home side on the scoreboard quarter of an hour in with a penalty of his own. And the full-back pulled Wales to within a point as Samoa were penalised for going in at the side, reaching 200 points for Wales in doing so - level with Gareth Thomas.
Wales still looked far from comfortable but with Samoa continuing to pile on the pressure in the Welsh half, the home side enjoyed a huge break as Pisi threw a wild pass straight into the hands of a grateful Beck, the centre running the length of the pitch from just outside his own 22 to score a debut try for Wales on home soil. Halfpenny added the extras to put them ahead for the first time 13-7. Pisi put Samoa back to within three with a late penalty as Wales ended the half narrowly in front.
Rob Howley’s half-time team talk seemed to have little effect and just as they had done at the start of the first half, Samoa shocked Wales with another try in the opening minutes. Referee Pascal Gauzerre played a knock on advantage and George Pisi finished off great work from Kahn Fotuali'i to acrobatically touch down in the corner.
Pisi missed the conversion but he and Halfpenny traded two penalties apiece to give Samoa a narrow 21-19 lead with 15 minutes remaining. Handling errors and indiscipline continued to hamper the home side’s chances, substitute fly-half Priestland taking the wrong option in kicking over the dead ball line with an overlap outside him.
And following a knock on from Ken Owens, Samoa launched one last, decisive attack. David Lemi evaded a couple of tackles before hacking on and the chasing Leota touched down in the corner after a slip from Halfpenny.
Again Pisi missed the conversion but it was too late for the home side to come back and the Samoan players celebrated a deserved fourth victory against Wales.
Even the late introduction of Sam Warburton for skipper Ryan Jones did little to inspire the home side. And with the All Blacks coming to town next weekend, Wales and Howley must pull a rabbit out of the hat to avoid a sixth defeat on the bounce.