Needing a win to guarantee a place in the last eight, Japan were ahead on 22 minutes when Maika Hamano finished from close range.
Mina Tanaka doubled Japan’s lead on 32 minutes with another strike from close in before Nigeria pulled one back through Jennifer Echeginiu on 42.
However it proved a brief respite for the Super Falcons, as Hikaru Kitagawa added a decisive third five minutes into added first half time.
Hasegawa gave a typically composed and tidy performance before being replaced on the hour-mark by Fuka Nagano.
Meanwhile, Aleixandri’s Spain needed to only avoid defeat against Brazil to book their place in the quarter-finals.
They did exactly that - and took all three points after Athenea del Castillo prodded home from a few yards out on 68 minutes to give the Spaniards a 1-0 victory.
Aleixandri’s dominant presence ensured Brazil’s attack were restricted to just two shots on target as La Roja completed their group stage with a 100% record.
Alexia Putellas doubled Spain’s advantage some 17 minutes (!) into added time to make it 2-0.
Their task was made that much easier when Brazil legend Marta was dismissed in first-half added time - though Brazil could yet progress as one of the best-placed third positioned teams.
Elsewhere, Mary Fowler and Alanna Kennedy face an nervous wait to see if Australia will make the last eight as one of the best third placed teams.
The Matildas went down 2-1 to the USA with Trinity Rodman giving the Americans the lead on 43 minutes.
Korbin Albert doubled the US lead on 77 minutes with a spectacular shot from distance, but the Aussies kept going and when Kennedy pulled one back a minute into added time, they piled the pressure on looking for un unlikely leveller.
It didn’t come, and now the City pair - who played the entire game -face an anxious wait on other results to see if they will extend their stay in Paris.