Perez's agreement was announced Tuesday, one day after his mother, Yilda Diaz, had her SUV stolen at gunpoint in Venezuela. His mother was unharmed and the vehicle was later recovered by the national police.
The extension will begin in 2017 and supersede his existing contract.
Perez signed with the Royals as a 16-year-old prospect from Venezuela, but shot through the minor league system. He made his big league debut in 2011, became the everyday backstop the following season and has made the All-Star game each of the past three years.
He hit .260 with a career-best 21 homers and 70 RBI last season, helping the Royals to their second consecutive World Series appearance. They beat the Mets in five games for their first title since 1985.