The Bianconeri are 21 points ahead of the Partenopei, who will have seven matches remaining after they face Genoa, and have a superior head-to-head record against them.
Milan were denied a first-half penalty when Hakan Calhanoglu's cross struck Alex Sandro's arm following a review via the video assistant referee.
Krzysztof Piatek gave the Rossoneri the lead in the 39th minute, though, after Tiemoue Bakayoko intercepted a poor pass out from the back by Leonardo Bonucci and slipped in the striker.
Paulo Dybala fired the Bianconeri level from the penalty spot on the hour-mark after Mateo Musacchio brought him down.
Substitute Moise Kean headed home Miralem Pjanic's corner, but the goal was ruled out for a foul on Alessio Romagnoli.
The 19-year-old grabbed the winner in the 84th minute with a low effort after Pjanic picked him out on the right.
Juventus Should Look to Kean After Ronaldo, Not Dybala
Despite having scored in each of his last four games for club and country, Kean started against Milan on the bench with Dybala up top alongside Mario Mandzukic.
With a crucial Champions League tie against Ajax looming on Wednesday and Ronaldo still working his way back to fitness after suffering a muscle strain on international duty, the opportunity was there to stake a claim for a place in the side if the Portuguese superstar isn't ready.
While both Dybala and Kean scored, it is the latter who put down a marker.
Aside from his penalty, the Argentinian cut an anonymous figure throughout his appearance on Saturday.
When he was taken off for Kean in the 66th minute, Bleacher Report's Gianni Verschuerentook note of his struggles this season:
Football writer Adam Digby saw an instant improvement in the team's play with Kean on the pitch:
Undeterred by his disallowed goal, the teenager grabbed the decisive winner with a fine finish:
The youngster's effort set Twitter alight, with Goal's Carlo Garganese calling for Kean to be ahead of Dybala in the pecking order on Wednesday:
Carlo Garganese @carlogarganese
Kean yet again. If Ronaldo is not fit to start on Wednesday v Ajax, Kean surely has to start instead of Dybala. He’s on fire right now and the pace and enthusiasm he brings is sorely missing when MM and Dybala are in attack. Too slow today with those 2 up front #JUVMIL
Kean now has the same number of Serie A goals as Dybala this season, in 19 fewer appearances.
Where Dybala has produced a number of ineffectual performances, Kean has a great deal of confidence and momentum on his side despite his age and status in the team.
The Italian would not only be a better choice to play against Ajax in the short term, but Juve should also be looking to him to take them forward when 34-year-old Ronaldo moves on or retires.
Juventus travel to Ajax for the first leg of their UEFA Champions League quarter-final on Wednesday before a trip to SPAL in Serie A on Saturday, the same day Milan take on Lazio.