The Turin club wrapped up an eighth successive league title last weekend but found themselves behind early on to a wonder-strike from Inter midfielder Radja Nainggolan.
However, the Portuguese responded with a powerful finish in the second half to make it 20 league goals for the season.
The goal moved Ronaldo within two strikes of Serie A’s leading scorer, Fabio Quagliarella of Sampdoria, in the process.
Inter remain in third place on 62 points, four ahead of AS Roma who are below them.
Juventus, who dropped points for just the sixth time in 34 games this season, moved up to 88 points.
This fixture, known as the “Derby d’Italia’’, is one of the country’s fiercest rivalries.
The home fans taunted the visitors with a pre-match mosaic of placards featuring the UEFA Champions League trophy alongside the words ‘Game Over’.
It was in reference to Juve’s quarter-final exit to Ajax Amsterdam in April.
The home support were left delighted just seven minutes in, when Nainggolan latched onto Matteo Politano’s dipping pass and unleashed a swerving volley from 25 yards out.
It flew past Juve goalkeeper Wojciech Szczesny.
Ronaldo drew Juventus level after 62 minutes, exchanging passes with Miralem Pjanic before drilling a left-footed finish into the bottom corner.
It was the 600th goal of the 34-year-old’s club career, with 450 having come at Real Madrid, 118 at Manchester United, 27 at Juventus and five at Sporting Lisbon.
The Portugal international is narrowly ahead of Lionel Messi, who scored his 598th goal for FC Barcelona on Saturday.