AC Milan scored a 120th-minute equaliser and then came out on top in a 24-penalty shootout to beat Rio Ave and reach the Europa League group stage.
Trailing 2-1 in the final seconds of extra time the visitors were awarded a penalty, which Hakan Calhanoglu converted.
That took the game to a shootout, with Milan coming out on top 9-8 in the 12th round of spot kicks.
The win means AC Milan will go into Friday's group-stage draw.
- 6BorevkovicBooked at 120mins
- 33de Jesus SantosBooked at 47mins
- 4Macedo Monte
- 8Vaz Alves MonteiroBooked at 68minsSubstituted forJamborat 75'minutes
- 5Carvalho SouzaBooked at 64mins
- 10Silva LopesSubstituted forOliveira Geraldesat 66'minutes
- 21Cardoso ManéSubstituted forde Souzaat 109'minutes
- 9Pereira Castro MoreiraBooked at 41minsSubstituted forMuondo Dalaat 86'minutes
- 7Muondo Dala
- 11Oliveira Geraldes
- 22da Silva Vieira
- 24Gaspar Amaral
- 70de Souza
- 77Ferreira Coelho Pereira
- 99G Donnarumma
- 24KjaerBooked at 113mins
- 19HernándezBooked at 61mins
- 79KessiéSubstituted forTonaliat 105'minutes
- 7Castillejo AzuagaSubstituted forDíazat 45'minutes
- 56SaelemaekersSubstituted forColomboat 95'minutes
- 27MaldiniSubstituted forda Conceição Leãoat 67'minutesBooked at 98mins
- 17da Conceição Leão
- Jesús Gil Manzano
- Shots on Target