Max Verstappen was leading the race with Leclerc in second position during the wet opening stint of the race at Suzuka, while Perez was isolated in third.
The front-runners maintained their positions after a switch to inters, but Leclerc started losing grip due to front tyre degradation, which gave Perez his opportunity.
The Mexican gradually closed the gap to Leclerc and was able to get close enough for a passing maneuvre on the final lap.
Leclerc cut across Perez to maintain his position at the final chicane, but the Frenchman was penalised for the move and given a five-second penalty, which resulted in Perez finishing second for a Red Bull one-two.
“It was a nice battle,” Perez told the media after the race.
“I think it was really tricky to overtake without DRS. I had to place [the car] into [Turn] 11 and out of 14 on the way to 17 on the back straight, but those places were where Charles was actually strong.
“I could see that he was managing well his race. His tyres, once he ran out of them, he was making it really hard, you know. So I knew that the only way I could get him was if I pushed him into a mistake.
“Towards the end, I thought there was one more lap left, so when he went off, I thought that was going to be the opportunity, but it didn’t happen. [In the end] we managed to get a good result for the team and a great one-two.”
READ MORE: F1 news: Martin Brundle says a ‘minor overspend’ could’ve given Red Bull a crucial edge