A comfortable 47-12 victory over Sri Lanka, with Jason Harries leading the way with a well-taken hat-trick, left Wales with an anxious wait as Kenya would have gone through instead of Wales if they could defeat Fiji.
In the last game of the evening, Fiji ran riot to crush Kenya 43-5 to end their hopes and ensure Wales went through as runners-up of the group.
Wales head coach Gareth Williams paid tribute to his side who fought back bravely against Kenya to snatch a last gasp victory thanks to Sam Cross's second try of the game.
"The game against Kenya was a prime example of never giving up. The hooter had gone and Kenya had a penalty but the workrate of the boys to get the ball back and the quality they showed to score in the corner was brilliant and it's that kind of belief and mentality we need to carry through tomorrow against New Zealand."
Wales followed up their heart-stopping 10-7 victory over Kenya with a seven try romp against Sri Lanka with Ross Jones, Luke Morgan, Lee Williams and Will Thomas adding tries to Harries' hat-trick. With Jones adding six conversions, Wales coasted to a 47-12 triumph.
Williams added: "Today was a good day's work by the boys, they managed their group superbly. New Zealand is going to be a huge challenge but we've made steps along the way over the past two weeks so hopefully we can take another one tomorrow," he said.
"The boys across the board have been excellent - it was good to see Ross Jones stepping up into the halfback position in only his second tournament; Will Thomas returning from injury was influential and we had a number of boys put their hands up throughout the day.
"We saw Jason Harries scoring a hat trick against Sri Lanka, Iolo Evans coming off the bench has made an impact while on the wing we've had Luke Morgan and Alex Webber to add some punch which keeps those two fresh and hopefully we've got enough in the legs to step up against New Zealand in the quarter-final tomorrow."