The Netherlands defeated Chile 2-0 on Monday to win their group and likely avoid a World Cup showdown with Brazil.
Super-subs Leroy Fer and Memphis Depay grabbed the late goals to settle a hard-fought clash in Sao Paulo.
The victory gave Holland a 100 percent record at the top of Group B after earlier wins against Spain and Australia.
More importantly the win is expected to see Louis van Gaal’s side steer clear of Brazil in the last 16, and play either Croatia or Mexico instead.
The identity of the Netherlands’ opponents will only be confirmed after the final matches in Group A later Monday.
Brazil face Cameroon in Brasilia while Croatia take on Mexico.
The Netherlands, missing suspended captain Robin van Persie, finally broke through Chile’s defense on 77 minutes.
Daryl Janmaat whipped in a cross and Fer rose high to thunder home a header.
In the dying minutes, Arjen Robben burst clear down the left flank and crossed for Depay to stab home from close range.
Spain defeated Australia 3-0 in Group B’s dead rubber, with David Villa, Fernando Torres and Juan Mata scoring.
Villa, 32, took his Spanish record goals tally to 59 in his 97th appearance with a clever backheeled finish on 36 minutes, in his last international appearance.
But Villa’s goalscoring finale was scant consolation for Spain after a disastrous World Cup campaign which saw the 2010 champions knocked out after their first two matches.
Villa, who will concentrate on a new club football career in Australia and the United States, was substituted early in the second half, shedding tears as he left the field to applause.
Torres added Spain’s second on 69 minutes, latching onto Andres Iniesta’s through ball and slotting past Maty Ryan.
Manchester United midfielder Mata completed the scoring.
Australia meanwhile exited with heads held high with another battling performance after running Chile and Holland close earlier in the tournament.
Later Monday, Brazil will look to book their second round berth with victory over Cameroon in Group A.
Brazil have failed to convince in their opening matches, grinding out a 3-1 win over Croatia before toiling to a 0-0 draw with Mexico.
However, a big win over an eliminated Cameroon could give them useful momentum heading into the last 16, where they would face Chile if they top the group.
The other final match in Group A sees Mexico and Croatia duel in Recife to determine who else advances, most likely in second place.
The final round of group fixtures began Monday with several fancied teams facing the prospect of an early elimination.
Tuesday’s games see Italy and Uruguay battling to avoid elimination in Group D where a win for either side will send them through to the last 16,
Costa Rica meanwhile will attempt to win the group, needing just to avoid defeat against England in Belo Horizonte.