Rafael, 21, arrived at Old Trafford in the summer of 2008 and his performances for the first team have seen him called into the full Brazil squad.
"Rafael is one of the club's brightest young prospects; he has no fear of playing and has great belief in himself," United manager Sir Alex Ferguson told the club's website.
"The boy has developed immensely since joining United, his energy and enthusiasm are a joy to watch.
"Rafael has all the attributes to become one of the best fullbacks in the world and I am delighted he has signed a new contract."
Meanwhile Rafael said: "I am so happy to sign a new contract. I love playing for Manchester United, there is a great team spirit here and a real desire to win.
"My time here has been unbelievable, winning two league titles, a league cup and a Club World Cup has made me hungry for more trophies.
"I would like to thank Sir Alex for his belief in me and I would also like to thank the fans for their support," added Rafael, whose twin brother Fabio is also in United's squad.
United finished runners-up in the Premier League last season, just losing out on goal difference to champions and local rivals Manchester City.