South Africa v Wales: Warren Gatland - Liam Williams apologetic

Full-back Liam Williams has apologised to his team-mates following Wales' 31-30 defeat by South Africa in the second Test, says head coach Warren Gatland.

Wales were leading 30-24 when referee Steve Walsh awarded a penalty try after Williams shoulder-charged Cornal Hendricks into touch just short of the try line.

Morne Steyn converted to deny Wales their first Test win in South Africa.

"He's devastated about that and apologised to the boys," Gatland said.

Referee Steve Walsh awards a late penalty try

Referee Steve Walsh awarded a late penalty try

"At this highest level, you just do not get away with anything and you've got to be squeaky clean.

"There were a few indiscretions that were costly to us and I think he'll learn from that experience and hopefully he doesn't do it again."

Gatland said he had no problem with Walsh's decision to award the late penalty try - South Africa's second of the game.

"We've made an error defensively, which is disappointing," Gatland added.

"Hendricks has got outside George [North] and unfortunately Liam's come in and led with his shoulder.

"I don't have an issue with the decision."

Tries from Jamie Roberts and Alex Cuthbert had put Wales in control in what was a dominant opening 25 minutes.

But with Luke Charteris and Dan Biggar sin-binned, South Africa got back into the game through a penalty try and a Cornal Hendricks effort.

Ken Owens' try extended the lead early in the second half, but Willie Le Roux's try and a converted penalty try gave the Boks victory.

Wales' tour of South Africa

10 June: Eastern Province Kings 12-34 Wales

14 June: South Africa 38-16 Wales

21 June: South Africa 31-30 Wales

"We were playing really well at 17-0 up and we've gone from a good position [and] quadrupled our errors," Gatland said.

"We've gone from a penalty to another penalty to a yellow card to another yellow card and again at this level, with top-quality referees, you don't get away with that.

"Those are big moments in the game where you're under a bit of control and we said to our players it's about game management."

New Zealander Gatland described the second Test defeat as one of the worst experiences of his coaching career as Wales failed to record what would have been only their second victory over South Africa.

"I'm pretty gutted about it. I'm proud of the performance, the turnaround and how the guys fronted up," Gatland said.

"It just shows you at this level it's about playing for the whole 80 minutes and being accurate when you do come under some pressure.

"I think it was a game that was there for us to win, but the best teams in the world never give up."