Milan had needed the three points after Fiorentina, who were just two points behind coming into the final set of fixtures, had crushed Pescara 5-1.
Siena took a shock lead when Claudio Terzi headed home from a free-kick as Milan struggled to find their natural rhythm or create any meaningful chances.
But just as it looked like the game was going to run away from Milan two second half red cards, Milan’s Massimo Ambrosini and Siena’s Christian Terlizzi receiving their marching orders, opened up the game.
And a late Mario Balotelli penalty gave the visitors hope before Philippe Mexes tucked home three minutes from time to seal a dramatic victory and send their supporters into raptures.
Milan’s task heading into the match was simple: win and guarantee Champions League football. Fiorentina lurked two points behind and were ready to pounce on any opportunity handed to them by Siena.
The early exchanges suggested they would comfortably do just that as Siena sat off and invited pressure with Antonio Nocerino blazing over early on when well placed.
Siena were in appalling form, on the back of five straight league defeats, and were already consigned to Serie B regardless of the outcome and yet, surprisingly, they went ahead when Terzi got his head on the end of an Alessandro Rosina free-kick.
News filtered through 300km southeast to Pescara that Milan were behind and Fiorentina set about piling on the pressure as they raced into a three goal lead inside half an hour.
Milan couldn’t break down a dogged Siena defence, relying on shots from distance and hopeful balls into the box as the match started to slip away from them.
The turning point arrived with twenty minutes remaining when the referee sent off a player from either side.
First he adjudged Ambrosini’s lunge to be reckless and handed the midfielder a second yellow before Christian Terlizzi launched himself off the ground in a kamikaze-style kick to also receive an early bath.
Mario Balotelli tested Pegolo with a couple of long range free-kicks but the clock was ticking and Milan needed two goals. Just as it looked like all hope was lost De Sciglio pumped a hopeful ball into the opposition penalty area and Balotelli was hauled to the floor. Penalty.
The striker picked himself up, dusted himself off and wrong footed the keeper from the spot.
And two minutes later they grabbed the goal that catapulted them into Europe’s premiere football competition. A free-kick evaded the entire Siena defence leaving Mexes one on one with Pegolo. His initial effort was saved, but the defender made no mistake with the rebound as the away end erupted, Viola hearts sank, and the Milan bench sprinted onto the pitch to celebrate.