Real looked comfortable and in control when Karim Benzema rounded Samir Handanovic to put his side in the lead and Sergio Ramos scored his 100th goal for the club to further extend their lead.
But the lead was short-lived as Lautaro Martinez scored from Nicolo Barella’s back heel pass and Ivan Perisic levelled with a composed finish from a Martinez header in the second half.
Rodrygo came off the bench in the 64th minute and proved to be a hero with a goal in the 80th minute.
Real are level on point with second-placed Shakhtar Donetsk with four points, one points behind leaders Borussia Monchengladbach with Inter at the bottom on two points.
During the match, at some point it looked as though they were going to have a comfortable night at the Alfredo di Stefano Stadium, before Martinez changed the outcome of the game with his stellar performance.
Achraf Hakimi’s terrible back pass gifted Karim Benzema an opportunity to round the Inter keeper to open up the scoring. Then, Ramos headed the second goal following a cross from Toni Kroos’ corner, making it his 55th headed goal and only the 19th player to reach a century of goals for Real.
The introduction of Rodrygo in the hour mark of the second half changed the outcome of the game, when both Brazilians Vinicius Jr and Rodrygo combined to put the home side in the lead, securing a 3-2 victory.
Real will return to face Inter Milan for the fourth round of the Champions League at San Siro for the second leg, after the international break.