"I saw the ball ricochet and it's a scary thing," Padres starter Kevin Correia said. "Being a pitcher, it's scary for you and it's scary for the hitter."
Gonzalez immediately fell to the ground clutching his head after he was hit by Jason Hammel's 93 mph fastball near the left ear hole on his batting helmet. After several minutes, Gonzalez was helped to a cart by the team's two trainers and driven off the field.
Manager Bud Black said he was told by the trainers on the field that Gonzalez was "conscious, he was lucid and he knew what happened. But he was extremely dizzy and his ears were ringing."
Black said Gonzalez had gone to a hospital for tests but the results would not be known until Sunday.
"It's something you don't want to see happen," Hammel said. "I hope he's all right. I'll be checking in on him. I was effectively wild and, unfortunately, effectively wild was dangerous."
Edgar's brother, All-Star Adrian Gonzalez, was pulled from the game when the inning ended to go to the hospital where Edgar was being treated.
Headley was pinch hitting in Adrian Gonzalez's spot in the lineup, which had been occupied by reliever Greg Burke (2-1) following several lineup changes. He fell behind 0-2 before he worked the count full and connected on his ninth homer to break a 1-all tie.
"You're trying to put the ball in play," Headley said. "Once you get to 3-2, it changes the at-bat a bit. But I'm just trying to get on base. I wasn't trying to hit a home run, but I got a good pitch to hit."
Joel Peralta (0-3) allowed Headley's homer and then gave up an RBI single to Eliezer Alfonso in the inning.
The loss was only the Rockies' 10th in 39 games since June 4. San Diego won for just the second time in 11 games, but still owns the majors' worst record (12-29) since June 1.
Heath Bell pitched the ninth for his 24th save in 25 chances to complete the combined four-hitter.
Correia allowed one run on three hits in six innings. Burke and Luke Gregerson pitched one perfect inning each.
"[Correia] was able to regroup and get through six innings when he really wasn't on top of his game," Black said.
"It wasn't pretty," Correia said. "I was able to make pitches when I needed to rather than just winging the ball up there. If that's going to a bad [outing], then that's pretty good."
Hammel gave up one run on five hits in 5 2/3 innings with seven strikeouts and three walks. Hammel also hit three batters.
After getting the first two outs of the sixth, Hammel hit Gonzalez, then walked pinch-hitter Drew Macias before he was pulled.
"He looked shaky to me," Rockies manager Jim Tracy said. "We gave him Macias and he looked very tentative. When we saw that, I don't think it was feasible to continue any further."
The Padres tied the scored when Hammel issued a two-out, bases-loaded walk to Kyle Blanks on four pitches. Hammel escaped further trouble when he struck out Alfonso.
It was the third time since the start of the four-game series against the Rockies on Thursday night that Alfonso has made an out with the bases loaded. In Thursday night's game, Alfonso stranded eight runners, including five in scoring position.
The home run was Headley's first as a pinch hitter. ... Rockies 3B Ian Stewart was held out of the starting lineup due to soreness behind his left knee. ... San Diego RHP Mat Latos, the club's top minor league prospect, makes his major league debut Sunday against the Rockies after getting called up from Double-A San Antonio on Saturday. RHP Josh Banks was designated for assignment.