Marcos Rojo scored a late winner as Argentina secured their place in the World Cup knockout stages at the Krestovsky Stadium on Tuesday evening.
In what was billed as a must-win match, Lionel Messi produced a stunning piece of skill to give the Argentines the lead in the 14th minutes. Nigeria were awarded a debatable penalty in the second-half, with Victor Moses coolly converting from the spot.
However, as it looked like Jorge Sampaoli's men were heading for an embarrassing group stage exit, Rojo stepped up to steer home and put Argentina into the last-16.
It was no surprise to see Nigeria boss Gernot Rohr name an unchanged team to the one that defeated Iceland 2-0 last time out. Ahmed Musa, who bagged two goals to secure the victory, again led the line.
Meanwhile, Sampaoli rung the changes as he made five alterations to the team that were humbled 3-0 by Croatia. Uncapped goalkeeper Franco Armani replaced Willy Caballero, whilst Sergio Aguero surprisingly dropped out to make way for Gonzalo Higuaín. Eduardo Salvio, Marcos Acuña and Fernando Meza dropped to the bench for Angel Di María, Éver Banega and Marcos Rojo.
Magic Messi finally arrives in Russia
It took a while for Argentina to really get going in Saint Petersburg, but when they did, they seized the advantage through Messi. Banega played a fantastic ball over the top of the Nigerian defence that the Barcelona superstar controlled expertly on his thigh. He allowed the ball to bounce once, before thrashing it home to notch his first goal of the World Cup.
Messi almost turned provider mid-way through the first-half as he played a sumptuous ball to Higuaín. Francis Uzoho advanced well to deny the Juventus hitman though.
Messi continued to put in a masterful showing throughout the first-half. After Di María had been tripped by Leon Balogun on the edge of the area, the 31-year-old stepped up to take the free-kick, with his low-effort cannoning off of the goalkeeper's near post.
Moses cool from the spot to equalise
Despite the Argentinian dominance in the first-half, Nigeria had the chance to equalise from the spot as Balogun was pulled down in the penalty area by Javier Mascherano only minutes into the second period. Moses stepped up and rolled the ball beyond Armani coolly to equalise and put the Nigerians in control of the runners up spot in the group.
Leicester City man Wilfred N'didi then did well to find space on the edge of the Argentine penalty area as Nigeria counter-attacked but his great effort was sent whistling over the crossbar.
Substitute Odion Ighalo had the chance to finish Argentina off after Ahmed Musa had raced down the wing. The former Watford forward was found in the centre but somehow sent his shot wide of the area. There was controversy as the striker appealed for handball off of Rojo, but VAR dictated that there would not be another penalty.
All out for Argentina
With the final whistle quickly approaching, Sampaoli had his final roll of the dice as he introduced Sergio Aguero. It almost paid off immediately as a low cross from the striker picked out Higuaín. The ex-Real Madrid star looked sure to score but lofted his shot wide over the crossbar.
Ighalo had another opportunity from close range but Armani saved well as Nigeria looked to put a stamp on the result. Oghenekaro Etebo also sent a free-kick crashing into the side-netting.
There was to be one final chance for La Albiceleste as Rojo stunned the Nigerians. Finding his way into the penalty in the final minutes of the game, the Manchester United man connected brilliantly with a cross to send the ball crashing into the bottom corner and to send Nigeria crashing out of the World Cup.
As a result, Argentina somehow squeeze past their opponents into the last-16 and set-up a clash with France, whilst Nigeria slip out of the competition despite an admirable showing in Russia.