McKinley's kicks cut the gap to 19-17 but the Welsh held on in a cliffhanger of a finish, with their out-half Matthew Jarvis' haul of 14 points (four penalties and a conversion) proving vital.
On another day, Allen Clarke's side may well have triumphed. They got off to an ideal start with a sixth minute try from winger Michael Keating.
But with Ciaran Ruddock ruled out of the game with an ankle injury, losing team captain Peter O'Mahony and his back row colleague Brian O'Hara to injuries in the first half and second half were two considerable blows.
David O'Callaghan and Joe Moran were very able replacements, however Wales were able to soak up the pressure and win through to a 5th-6th place play-off decider against France.
Speaking after the game, Irish coach Clarke was left ruing the missed scoring opportunities that will make the match video doubly frustrating for his players to watch.
"Obviously we're disappointed, we've got to look at ourselves," he said.
"We've also got to give credit to Wales. They made it difficult for us out there in aspects of our game, which contributed to our mistakes.
"Having said that, we know that we're better than that. We left opportunities out there on the field.
"It wasn't lack of work-rate or lack of desire, it was about our own accuracies."
That same work-rate was obvious throughout Ireland's pool games against Argentina, New Zealand and Uruguay, and they will need to hit a high level of performance once again when they meet Samoa on Sunday (kick-off 12pm local time/4am Irish time).
This season has been a very encouraging one at this level, with Ireland finishing second in the RBS Under-20 6 Nations Championship - beating France, Italy, England and Wales along the way - and a number of players from the U-20 Development squad that defeated France also appearing on the Junior World Championship stage.
Disappointing as it was not to qualify for the semi-finals in Japan or reach the 5th-6th place play-off, there is some consolation in that both of Sunday's JWC finalists, New Zealand and England, have had a tough time of it against Ireland this season.
Clarke's charges scored a dramatic 19-18 victory over England in the Six Nations, and last week they put in the best performance by a Northern Hemisphere side against the Baby Blacks for some years.
Samoa now stand in their way of a seventh place finish and the Irish youngsters will certainly be determined to end the tournament with a bang.
"From here on in, we've got to ensure that the players recover mentally and physically for what's going to be an important game on Sunday," Clarke added.
"We've got seventh place to fight for now.
"Against Wales we didn't get to the level, in terms of our game, that we aspired to and the level that we showed against New Zealand.
"However, we've got to regroup. That's what sport is about - it's about recovering physically and mentally so that these players, who had a really good season, finish it on a high."
Giving the players' point of view, hooker Tom Sexton expressed the mood of the entire squad in losing narrowly to Wales.
"We're very disappointed. We put a lot of effort in but unfortunately we just didn't capitalise on our possession and take our opportunities," he said.
"The Welsh took their opportunities and in fairness to their out-half, he kicked very well as did our 10.
"We just need to be more clinical in the way we play and stop turning the ball over as much. That's the main aspect we're disappointed with."