Alonso took his first podium for Aston Martin in seven races in spectacular style by duelling with Red Bull's Perez over the final laps at Interlagos.
Perez passed the Spaniard in Turn 1 on the penultimate lap, but Alonso retaliated one lap later with an outside pass into Turn 4.
He then barely held on in a drag race to the finish, with Perez passing him right after the chequered flag, the difference being 0.053s at the line.
Alonso admitted he thought his podium was lost when Perez steamed past on Lap 70 of 71, but explained that a late braking manoeuvre by Perez in Turn 1 opened up an opportunity for him into Turn 4 on the final lap.
"For me, it was like 30 laps that I had the pressure from Checo but when he passed me two laps to the end, I thought: 'Okay, this is gone, the podium is not possible anymore'.
"But he braked a bit late into [Turn] 1 and I said : 'Okay, I go for it into [Turn] 4.'"
Source: Autosport