Jody Gerut, Kevin Kouzmanoff and Giles homered in the third, and Luke Carlin added his first major league home run. Giles scored four times and had four RBIs for the Padres, who had 20 hits and set a season-high in runs.
Giles, a San Diego native, was claimed on waivers by the Red Sox on Wednesday but the veteran invoked his no-trade clause to remain with the Padres.
"I felt relaxed when I made the decision," he said. "It wasn't a big issue for me."
The Padres wasted little time in welcoming Hernandez back to the NL. Gerut and Luis Rodriguez led off the game with singles, Giles hit a two-run double and Gonzalez doubled home a run. Later in the inning, Carlin drove home Gonzalez to make it 4-0.
Hernandez (0-1), claimed off waivers by the Rockies on Wednesday, pitched a perfect second inning but didn't get out of the third. He walked Gonzalez and gave up a two-run homer to Kouzmanoff, his 17th of the season. After Chase Headley popped out, Hernandez walked the next two batters and Gerut chased him with a line-drive, three-run homer to right-center, his 11th of the season.
"Livan is a real good control pitcher and he just didn't have his control like he usually does," Giles said. "We were able got get him into good hitting counts, and when he did leave it over the middle, do some damage with it."
Hernandez had allowed a major league-high 199 hits and .341 opponent batting average before he was waved. A move to Coors Field, coupled with nearly two weeks off, wasn't the antidote to those problems.
Hernandez allowed nine runs on seven hits and walked four in 2 2/3 innings, but the Padres didn't stop scoring once he left. Rodriguez greeted reliever Jason Grilli with a single and Giles followed with a home run that bounced off the top of the right-field fence.
"I didn't pitch for 12 days," Hernandez said. "I leave a lot of pitches on top of the plate. I'm better than that; I know that."
Rockies manager Clint Hurdle said Hernandez's ineffectiveness was a combination of rust and location.
"His command wasn't sharp," Hurdle said. "He wasn't able to throw quality strikes on either edge, and the balls were hit hard."
Down 11-0, the Rockies mounted a rally off of starter Chris Young in the fourth, scoring seven runs on seven hits. Cory Sullivan had a two-run triple and Brad Hawpe's 18th home run, a three-run shot into the Rockies' bullpen, made it 11-7.
"I've been in this park a number of times, but I'm hopefully a quick enough study to realize the more runs you get here the better you feel," Padres manager Bud Black said.
Young gave up seven runs and nine hits with three walks three in four innings. Justin Hampson (1-1) pitched three innings in relief to get the win.
Colorado has lost five of seven to Washington and San Diego, two of the worst road teams in the major leagues, on this 10-game homestand. Only the Rockies have a worse road record.
"We've been playing so well at home all year, to have a big homestand and get beaten by two teams we feel we should play better than is tough to take," shortstop Troy Tulowitzki said.
The Rockies are eight games behind Arizona in the NL West and host the Diamondbacks for a three-game series starting Tuesday.
"We'll know where we are at the end of those three games," Hurdle said.
Plate umpire Derryl Cousins left the game in the third with an inner ear infection. First base umpire Mike Muchlinski replaced Cousins behind the plate. ... The Rockies transferred 1B Todd Helton from the 15-day DL to the 60-day DL. Helton was placed on the DL with a strained back July 3. ... Padres RHP Bryan Corey (strained left hamstring) is day to day. ... Giles got his 1,800th career hit with a double in the first inning. ... Colorado's Matt Holliday has scored at least one run in a franchise-record 15 straight games.
Rockies rally, win in 10th as Dodgers' bullpen woes continue
— Trevor Story homered and drove in the go-ahead run in the 10th inning as the Colorado Rockies took advantage of the Dodgers' recent bullpen woes, beating Los Angeles 9-6 Friday night.
Blackmon launches 2-run homer in 10th
Charlie Blackmon extends the Rockies' lead with a two-run home run in the 10th inning vs. the Dodgers.
Hilliard's homer gives Rockies lead in 9th
Sam Hilliard finishes off the Rockies' comeback with a solo home run in the top of the ninth vs. the Dodgers.
Raleigh, Torrens hit back-to-back HRs, Mariners top A's 4-3
— Cal Raleigh and Luis Torrens hit back-to-back homers, Dylan Moore scored the go-ahead run on consecutive wild pitches and the Seattle Mariners beat the Oakland Athletics 4-3 on Friday night.
Cal Raleigh demolishes 1st career HR, Mariners go back-to-back
Cal Raleigh sends his first big league home run 444 feet as the Mariners hit back-to-back dingers in the second inning of a 4-3 win over the A's.
Reynolds HR, Pirates stop 4-game skid, beat Giants 6-4
— Bryan Reynolds homered, Adam Frazier drew a bases-loaded walk to force in the go-ahead run in the seventh inning when Pittsburgh scored three times without a hit, and the Pirates beat the San Francisco Giants 6-4 on Friday night.