Spanish great Nadal and longtime friend Marc Lopez defeated Romania’s Florin Mergea and Horia Tecau 6-2, 3-6, 4-6 in the men’s doubles title match.
Nadal, the 2008 singles champion in Beijing, is just the fourth player to win gold in singles and doubles after Serena and Venus Williams and Chile’s Nicolas Massu.
Earlier, the 30-year-old defeated Brazil’s Thomaz Bellucci 2-6, 6-4, 6-2 in the singles quarter-finals.
The 14-time major winner faces Juan Martin Del Potro of Argentina on Saturday for a place in the final.
Del Potro, the 2009 US Open champion who was pushed to the brink of retirement by years of wrist trouble, downed Spain’s Roberto Bautista Agut 7-5, 7-6 (7/4).
The Argentine, who knocked out world number one Novak Djokovic in the first round, wept in his courtside chair at the end of the quarter-final in which he fired 42 winners.
Defending champion Andy Murray will face Japan’s Kei Nishikori in the other semi-final.
In the women’s singles, Monica Puig made Saturday’s final where she will play Germany’s Angelique Kerber for the chance to win Puerto Rico’s first gold medal.
Del Potro has seen his ranking slip from four in the world to 141 after undergoing three surgeries and missing large parts of the last two seasons.
‘’Every time I play here, the crowd makes me cry,’’ said the 2012 bronze medallist who once again enjoyed the support of a legion of boisterous fans wearing Argentina football shirts.