Juve’s triumph also meant tiny Sassuolo, who have completed only three seasons in the top flight since making their Serie A debut in 2013-14, qualified for Europe for the first time.
Milan, who finished seventh in the league after another dismal season, surprisingly looked the more dangerous team at Rome’s Stadio Olimpico but failed to take their chances.
Juventus, Serie A champions for the last five seasons, snatched the win 10 minutes from the end of extra time when Morata swept the ball home after a counter-attack from deep in their own half.
Meanwhile, several thousand fans gathered in the main square of Sassuolo which, with a population of about 40,000 is the smallest town ever represented in Serie A.
Sassuolo finished sixth in the league, the highest-placed team outside the automatic European berths, and took Juve’s place in the Europa League.
Juventus coach Massimiliano Allegri said his team had found the last few weeks heavy going, having wrapped up the Serie A title with three games to spare.
“It wasn’t easy for the players because they’d basically been without much motivation for the last few weeks and needed to get their minds back in the right place to win,” he told Rai sport.
Cristian Brocchi, Milan’s fifth coach in the last three seasons and whose future is uncertain, praised his side’s performance, a sharp contrast to his fierce criticism after they lost 3-1 at home to AS Roma in their final league game.
“Tonight, I saw for the first time a bit of my influence in this team,” he said. “I saw the right mindset and right attitude. We were punished by an episode. They have great players, that’s football.”
“We didn’t deserve to lose and are left with a sense of regret.”
Milan created all the best chances in the first half but failed to take any, with Giacomo Bonaventura and Andrea Poli the main culprits.
Both teams were more dangerous in the second half although Juventus had the best opportunity when Gianluigi Donnarumma, Milan’s 17-year-old keeper, parried a deflected Paul Pogba shot.
Morata made an instant impact after replacing Hernanes in the 108th minute and Milan never looked like clawing back the deficit once they had fallen behind.