Colombia forward Luis Diaz scored a stunning 25-yard injury-time winner to help his country beat Peru 3-2 in their Copa America third-place play-off.
Yoshimar Yotun had given Peru the lead in the first half only for Juan Cuadrado to equalise with a free-kick shortly after the break.
Diaz then put Colombia in front before a Gianluca Lapadula’s 82nd-minute header levelled the match again.
A penalty shootout looked on the cards but Diaz scored in the 94th minute.
“We’re happy – it was important to finish by winning,” said Cuadrado. “I’m happy with how we reacted [to going behind] and how we went after the result.”
Argentina, who beat Colombia on penalties in their semi-final, will play hosts Brazil, who beat Peru 1-0, in the final at 01:00 BST on Sunday in a game that will be live on BBC One and BBC iPlayer.
- 13MinaSubstituted forD Sánchezat 55′minutes
- 3MurilloBooked at 87mins
- 11Ju Cuadrado
- 5BarriosBooked at 62minsSubstituted forMurielat 90+3′minutes
- 8CuéllarSubstituted forBorréat 83′minutes
- 10CardonaBooked at 45minsSubstituted forCharáat 45′minutes
- 7ZapataSubstituted forBorjaat 55′minutes
- 23D Sánchez
- 3CorzoSubstituted forLoraat 78′minutes
- 13TapiaSubstituted forCartagenaat 24′minutes
- 18CarrilloBooked at 63mins
- 8PeñaSubstituted forOrmeñoat 78′minutes
- 10CuevaBooked at 50minsSubstituted forGarcíaat 69′minutes
Match ends, Colombia 3, Peru 2.
Second Half ends, Colombia 3, Peru 2.
Goal! Colombia 3, Peru 2. Luis Díaz (Colombia) right footed shot from outside the box to the top right corner. Assisted by Luis Muriel.
Substitution, Colombia. Luis Muriel replaces Wilmar Barrios.
Foul by Marcos López (Peru).
Juan Cuadrado (Colombia) wins a free kick in the defensive half.
Óscar Murillo (Colombia) is shown the yellow card for a bad foul.
Gianluca Lapadula (Peru) wins a free kick in the defensive half.
Foul by Óscar Murillo (Colombia).
Attempt missed. Miguel Borja (Colombia) left footed shot from the left side of the box is too high following a corner.
Corner, Colombia. Conceded by Marcos López.
Wilder Cartagena (Peru) wins a free kick in the defensive half.
Foul by Miguel Borja (Colombia).
Substitution, Colombia. Rafael Borré replaces Gustavo Cuéllar.
Goal! Colombia 2, Peru 2. Gianluca Lapadula (Peru) header from very close range to the bottom right corner. Assisted by Raziel García with a cross following a corner.
Corner, Peru. Conceded by William Tesillo.
Foul by Santiago Ormeño (Peru).
Davinson Sánchez (Colombia) wins a free kick in the defensive half.
Wilder Cartagena (Peru) wins a free kick in the attacking half.
Foul by Yimmi Chará (Colombia).