ST PETERSBURG (Reuters) - Argentina and Lionel Messi scraped into the knockout stages of the World Cup by the skin of their teeth on Tuesday after an 86th minute strike from defender Marcos Rojo gave them a barely deserved 2-1 win over Nigeria, eliminating the African side.

Soccer Football - World Cup - Group D - Nigeria vs Argentina - Saint Petersburg Stadium, Saint Petersburg, Russia - June 26, 2018 Argentina's Marcos Rojo celebrates scoring their second goal with Lionel Messi REUTERS/Henry Romero

The twice World Cup champions will face France in the last 16 while Croatia, who advance as winners of Group D with the maximum nine points after beating Iceland 2-1, will take on Denmark.

Nigeria were just minutes away from progressing before central defender Rojo superbly volleyed home a Gabriel Mercado cross from the right.

As the drama unfolded in St Petersburg, Iceland were simultaneously fighting with all their Nordic might for a win over the Croats in Rostov-on-Don that could have sent them through. The Argentines, however, had enough on their plate with a feisty Nigeria to worry about results elsewhere.

Messi had put them ahead in the 14th minute, with a fabulously taken goal but the Africans equalized through a Victor Moses penalty in the 51st minute. The South Americans struggled to respond to that setback with a ragged second half display.

For all their attacking talent, it was their center half Rojo who delivered the decisive blow with a powerful and accurate strike that Messi himself would have been proud of.

“We already knew we were going to win, we were confident that God would help us, that all would turn out well. But we didn’t expect the complication of the draw, of suffering so much.

“What’s important is that we went through,” said Messi, who had been cheered on by compatriot Diego Maradona watching from the stands, along with a massive following of passionate and loud Argentine supporters.

The game began in ideal fashion for Jorge Sampaoli’s side, who had managed just a point from their opening two games.

A perfectly weighted diagonal ball over the top by Ever Banega was sublimely brought down on the outside of his thigh by Messi who then drove past Nigeria’s teenage keeper Francis Uzoho to open the scoring.

The selection of Banega proved to be an inspired one by Sampaoli, with the Sevilla midfielder providing the quality service that had been lacking so far in Russia.

It had been an impressive half from Argentina but the game was to take a twist shortly after the interval.

Defending a corner, Argentine defender Javier Mascherano jockeyed Leon Balogun inside the area and when the Nigerian fell to the floor, Turkish referee Cuneyt Cakir awarded a penalty.

Slideshow ( 26 images )

After lengthy and impassioned protests from the Argentine players, Moses managed to keep his cool and slot past Franco Armani to level the scores.

WASTED CHANCES

Nigeria wasted several chances to add a second and secure their place in the last 16 and they were furious that a video assistant referee (VAR) review failed to award them a penalty for a possible handball by Rojo.

At the other end, Gonzalo Higuain blasted over when free in the area, a miss that could have haunted him almost as much as those from the loss to Germany in the final four years ago in Brazil.

But saving Higuain and his team mates was the unlikely source of Manchester United central defender Rojo who kept Argentina’s tournament alive and left Nigeria, who had been positive and aggressive throughout, in total despair.

“It is what it is. It just wasn’t to be,” said captain John Obi Mikel.

“It is a young team, though, and in four years most will be ready for this tournament. I’m very proud of the boys, they’ve done really well.”

While Nigeria will look to the future, Argentina are very much in the present as they head into the knockout stages for the fourth consecutive World Cup finals, since being eliminated in the group stage in 2002.