They combined to hand Hernandez one of the more forgettable performances of his career.
Rendon hit the first of Washington's four homers off Hernandez, and the Nationals showed off their power in an 8-3 victory over the Seattle Mariners on Friday night that snapped a three-game losing streak.
Rendon hit a solo shot in the first, and Werth, Desmond and Ramos also connected against Hernandez (13-5). It was the first time Hernandez had allowed four homers in a game.
"I don't think it was necessarily what he did, it's more what we did," Desmond said. "We brought a good approach to the plate today and we were able to fight off some tough pitches. He was making good pitches down in the zone and we forced him to get the ball up and we were able to make him pay."
Werth's two-run shot in the third gave the Nationals a 3-2 lead, and Desmond added his 22nd an inning later.
Hernandez lasted seven innings and was charged with five runs and 10 hits. He is 0-2 with a 5.09 ERA in his last three starts.
"I couldn't get out of the middle of the plate the first four innings," Hernandez said.
Jordan Zimmermann (10-5) struck out eight in six innings for Washington. He allowed two runs and seven hits while improving to 4-0 in six August starts.
Zimmermann gave up two runs in the first and threw 33 pitches. The long inning became a benefit as the fatigue helped him keep the ball down in the zone.
"I was a little strong the first, second inning. Fastball was up and I couldn't get it down," Zimmermann said. "Throwing that many pitches helped me a little bit."
Rendon jumped on a first-pitch fastball in the middle of the strike zone for his 18th homer. The homers for Desmond and Ramos against Hernandez also came on pitches up in the zone. Werth golfed a breaking ball out to deep left-center field.
"I think they were patient enough to get good pitches to hit," Nationals manager Matt Williams said. "When he's successful he's throwing the ball and it looks like it's in the zone and it's not. We got balls up in the strike zone today."
Seattle lost consecutive games for the first time in more than a month and fell a game behind Detroit in the race for the second wild card in the American League.
The Nationals entered Friday fifth in the National League in homers, but the long-ball outburst was surprising considering the starting pitcher and the ballpark. Washington had six games with three or more homers this season, but the six long balls were the most for the Nationals since 2012. It was the eighth time in franchise history hitting six homers.
"It's not how we live by any stretch," Williams said. "Generally we're putting good at-bats together but tonight it worked."
After setting a major league record with 16 consecutive starts of seven innings and two or fewer runs, Hernandez has looked mortal recently. Seattle pushed Hernandez back an extra day, but the move backfired. Hernandez had been 7-0 with a 1.77 ERA this season when starting after getting five or more days of rest.
Nationals: Werth got the nod at designated hitter against Hernandez to give his sore ankle a break.
Mariners: Michael Saunders went through a pregame workout as he continues working back from a viral infection that saw him lose 12 pounds. Saunders was on a rehab assignment when he fell ill and there is no timetable yet for his return.
Nationals: Stephen Strasburg (10-10) makes his 29th start. He won his previous two decisions to get back to .500 for the season. He got a no-decision in his last start against San Francisco giving up five earned runs in four innings.
Mariners: Seattle made a switch and will throw left-hander Roenis Elias (9-11) on Saturday night. Chris Young will get a couple extra days of rest and will throw Monday's series opener in Oakland. Elias has lost three of his last four starts and hasn't pitched six innings since late June.