Mario Balotelli and Philippe Mexes scored late on at Siena as Milan came from behind to secure a place in the UEFA Champions League.
Balotelli’s 84th-minute penalty had cancelled out Claudio Terzi’s first-half header, before Mexes netted a crucial winner three minutes from time.
A hard-fought second half saw both sides reduced to 10 men in the space of just a few minutes after Massimo Ambrosini and Christian Terlizzi were both sent off for second bookable offences.
But it was the late goals that made all the headlines as Milan guaranteed their place at European football's top table in dramatic circumstances.
Milan came into the game needing to win in order to beat Fiorentina to the final UEFA Champions League place, and they made five changes to the team that played out a controversial 0-0 draw with Roma last week.
Sulley Muntari's bizarre red card in that game meant that he was suspended, while Ignazio Abate was preferred ahead of Kevin Constant.
Robinho, Antonio Nocerino, Riccardo Montolivo and M'Baye Niang were all handed starts.
Siena, whose relegation was confirmed with a 2-1 loss away to Napoli, welcomed back Alessandro Rosina.
Milan began the game with an expected level of urgency, creating a flurry of chances during the opening exchanges.
Balotelli was the first to test Gianluca Pegolo in the Siena goal, seeing his stinging long-range effort tipped over the crossbar.
A few moments later, Cristian Zapata saw a header cleared off the line before Brazilian Robinho was unlucky not to break the deadlock when he saw his vicious swerving shot palmed away by Pegolo.
And Milan were made to pay for their profligacy just before the half-hour mark when the hosts took an unlikely lead through Terzi.
A pinpoint free-kick from Rosina found the head of the defender, who took advantage of some slack Milan marking to direct his header past Chrisitan Abbiati.
Milan nearly conjured up the perfect response just two minutes later, when Balotelli crashed a shot onto the crossbar.
And the Italian was involved again just before half-time, forcing a decent save from Pegolo as Siena weathered the Milan storm.
The second half began in similarly frustrating circumstances for Milan, as they struggled to find a decisive final ball. And 10 minutes later they were down to 10 men when Ambrosini slid in rashly on Adrian Callelo and was shown a second yellow card.
The numbers were even soon after, though, as the home side were also down to 10 men - Terlizzi given his marching orders for jumping into a challenge with Balotelli.
Balotelli made his mark in some style 10 minutes from time when he was brought down in the box by Felipe to give Milan hope.
The Italian brushed himself down to calmly slot home the resulting spot-kick and the comeback was on.
Then, with just two minutes to go, Mexes found himself on the end of a Montolivo cross to slot home the dramatic winner.
|88||C. Terlizzi||45' 70'|
|14||F. Della Rocca|
|Coach: G. Iachini|
for A. Rosina 61'
for I. Emeghara 75'
for M. Rubin 89'
|Everton profited from ´harsh´ refereeing, claims Delaney|
|We will get much better, Guardiola warns rivals|
|Ibrahimovic turned down €100m China deal - Raiola|
|Everton 1 Crystal Palace 1: Benteke cancels out Lukaku opener|
|Rashford looking to emulate Ronaldo at Manchester United|
|Managers given bad name by Allardyce scandal - Moyes|
|Pagliara claims he lied to Telegraph over bungs|
|Dyche excited by Arsenal challenge|
|Mazzarri wary of unleashing Success until he is fully fit|
|Moyes stands by criticism of players|
|Guardiola marvels at amazing Ryder Cup experience|
|Mathieu and Deschamps ´exchange´ gives Mangala recall|
|Retirement threat just ´erratic´ Tevez being dramatic - Joorabchian|
|Dani Alves wants Champions League glory with Juventus|
|Guardiola: Football fans can enjoy Tottenham|
|Ranieri calls for consistency from Leicester|
|Low missing out on ´dream´ player in Castro - Tuchel|
|Mata: I never had problems with Mourinho|
|Conte wants failures to motivate Chelsea|
|Pochettino rules out ´impossible´ England switch|
|Emery pleased with Ben Arfa attitude|
|Gundogan returns for Germany after lengthy absence|
|Terry out again as Chelsea prepare for Hull|
|Hasselbaink refutes corruption allegations|
|Robben to start against Cologne, suggests Ancelotti|
|Prolific Callejon called into Spain squad|
|Hull City offer ´keeps changing´ - Phelan|
|Krueger: Black allegations do not directly affect Southampton|
|Wenger optimistic over Coquelin recovery|
|Hughes focused after Mourinho backing|
|Wenger open to England job|
|Klopp eyes retirement before 60|
|Wenger the pioneer battles on within his own legacy|
|Lukaku: I am not on Suarez´s level yet|
|Ibrahimovic is tremendous even if he does not score - Mourinho|
|CONCACAF Champions League Review: Olimpia, Honduras Progreso claim key wins|
|Astra expected hungover Roma - Spalletti|
|United fixture list a ´poisoned gift´ - Mourinho|
|Ronaldo back for ´stronger´ Portugal|
|Dembele can be next Drogba - Rodgers|
|Mourinho wanted Pogba at Chelsea, says Raiola|
|Puel pleased with ´good point´ in Israel|
|Mourinho not ´over the moon´ with United wins|
|Southampton investigating Eric Black allegations|
|Rodgers: Celtic would challenge at the top in England|
|Ibrahimovic expects more from United|
|Manchester United 1 Zorya 0: Ibrahimovic header earns Mourinho´s men narrow win|
|De Boer blasts Inter for lack of focus|
|Zarate reveals message to ill wife after goalscoring return|
|Raffael suffers fresh injury setback|
|Hapoel Be´er Sheva 0 Southampton 0: Saints´ winning run comes to an end|
|Sparta Prague 3 Inter 1: De Boer´s side humbled in Europa League again|
|Police to review corruption allegations after Telegraph sting|
|Brady hails Wenger as ´possibly the best ever´ Gunners boss|
|Yacob signs new West Brom deal|
|Guidolin prioritising Swansea improvement over his future|
|Sakho outburst has been dealt with – Klopp|
|Bilic sorry for Allardyce in ´very sad´ week for English football|
|Laporte saga nears conclusion as defender earns France call-up|
|Everton are exceeding expectations – Koeman|
|Wenger could be tempted by an international offer, says ex-assistant|
|No excuses for Liverpool this time, says Klopp|
|Rashford left out of England Under-21 squad|
|Boro must pick up where they left off - Karanka|
|Matuidi could still join Juventus, says Raiola|
|Pardew anticipates battle of the Belgians|
|Legia Warsaw to face Real Madrid behind closed doors|
|England job would be the pinnacle - Pardew|
|Wright sacked by Barnsley|
|Bilic defends West Ham team night out|
|Ramsey withdrawal was Arsenal´s call - Coleman|
|LMA demand ´immediate full disclosure´ of corruption evidence|
|´My answer would be a big fat no´ - Coleman rules out taking England job|
|Leeds dismiss Cellino sting as ´non-story´|
|Gabigol, Rashford and Sanches among Golden Boy nominees|
|Keane slams Arsenal: Half their players will have gloves on soon|
|´Special´ Man City draw a career highlight, says Gordon|
|Southgate admits England situation is ´not ideal´|
|England should have gone for O´Neill, says Shilton|
|PSG´s powers of recovery impress Cavani|
|Howe ´absolutely committed´ to Bournemouth amid England links|
|Man City proved character against Celtic, says Zabaleta|
|Walcott: Sanchez partnership bodes well for Arsenal´s season|
|MLS Review: DC, Impact on track for play-offs|
|CONCACAF Champions League Review: Tigres, Dallas left waiting|
|Central Sanchez pleases Wenger|
|Barca felt Messi absence - Busquets|
|Martino knew Messi would come out of retirement|
|Shilton never convinced by Allardyce|
|Degenek replaced by Giannou for Socceroos|
|Griezmann will still take penalties - Simeone|
|Simeone proud of ´one of the best´ wins|
|Godin suffers sprained ankle ligament|
|West Ham receive positive news over injured duo|
|Robson: Four wins for Southgate and he´s an England contender|
|Gunes rues Besiktas´ inability to see off Dynamo|
|Sarri: Late goals leave bitter taste|
|Borussia Monchengladbach were exceptional against Barcelona, feels Schubert|
|PSG must be patient, says Emery|
|Celtic are lucky to have Dembele - Rodgers|
|I´m completely focused on Arsenal, insists Wenger amid England talk|