Updated

Daniel Bard had already survived perhaps the wildest inning of his major league career, one that included a pair of balks and a wild pitch, when he headed out for the eighth inning.

He headed right back to the dugout after issuing a pair of walks.

Red Sox reliever Matt Albers came into the game to face Billy Butler, clinging to a one-run lead, and Kansas City's designated hitter pounced on the third pitch he saw, the three-run homer lifting the Royals to a 6-4 victory over Boston on Tuesday night.

"I thought he was in complete control of the game," said Red Sox manager Bobby Valentine, who made the decision to send Bard out for the eighth inning.

"After the second inning when he kind of gave away three runs, he was in complete control of the game with all of his pitches," Valentine said. "I was very surprised to see him walk those hitters. I had Matt ready in case something happened. Something happened."

Bard (2-4) ended up with a memorable line: He gave up five runs on six hits and four walks, while also throwing a wild pitch and getting called for two balks during the same at-bat.

"I felt great. I felt strong. You get to 90 pitches, I'm not tired to where I think I need to come out of the game," he said. "There is a fatigue that sets in. It's about learning how to pitch with that little bit of fatigue. It's not my arm. My arm felt great."

Chris Getz and Humberto Quintero also drove in runs for the Royals, who overcame another lousy performance by their starting pitcher to pick up a confidence-boosting win.

Kelvin Herrera and Jose Mijares (2-1) had kept Kansas City in the game after Danny Duffy lasted just 4 1-3 innings. Jonathan Broxton worked the ninth for his sixth save.

"The way things have been going, we haven't come back in games," Butler said. "Hopefully that gets us going. Hopefully we can feed off that."

Dustin Pedroia had two RBIs and Kelly Shoppach also drove in a run as Boston lost for the sixth time in seven games, two of those defeats coming in extra innings.

Boston rookie Will Middlebrooks followed up his two-homer, five-RBI game in the series opener with a double in the second inning, joining Hall of Famer Enos Slaughter as the only players since at least 1920 to record an extra-base hit in each of their first five major league games.

Marlon Byrd and Shoppach added back-to-back two-out singles to drive in Middlebrooks, who felt tightness in his left hamstring and left the game between half innings. Duffy proceeded to walk Mike Aviles and Pedroia to give the Red Sox a 2-0 lead.

Kansas City answered with three runs in the bottom half of the second inning.

Eric Hosmer singled and Jeff Francoeur drew a walk before Mike Moustakas grounded out to second base, hustling down the line to avoid the double play. That's when Bard was hit with his first balk, which allowed Hosmer to score and sent Moustakas to second base.

Bard argued vehemently with plate umpire Tim Tschida to no avail.

The young right-hander really got riled up when he stepped off the rubber and tried to chase Moustakas back to second base. Bard was hit with another balk, allowing Moustakas to reach third, and the mistake proved critical when Getz's single tied the game.

"It was really weird," he said. "I can't remember the last time I balked in my life, ever. I don't think I've done it in the big leagues."

Quintero's two-out base hit gave Kansas City the lead, but the plodding catcher — with one career stolen base — ended the inning when he was thrown out trying to swipe second.

Duffy could have used some more support the way he was going.

Pedroia knotted the game in the fourth with a single, and the Red Sox pulled ahead in the fifth thanks to more erratic pitching and some lousy Kansas City defense.

Adrian Gonzalez doubled and Nick Punto walked with one out, and Duffy was yanked for reliever Kelvin Herrera. He got Ryan Sweeney to ground into what should have been an inning-ending double play, but Getz threw wide of Hosmer at first base, allowing Gonzalez to score.

The Red Sox remained in front until Butler's game-changing homer.

"I'm just going to let Big Bill do what Big Bill does," Royals manager Ned Yost said, "hit one in the gap — and he did a little more than that."

Notes: Boston 3B Kevin Youkilis (lower-back strain) exercised before the game. He's eligible to come off the DL on Monday, though manager Bobby Valentine isn't sure if that will happen. CF Jacoby Ellsbury (dislocated right shoulder) also worked out. "This is the beginning of the next step in his program," Valentine said. ... The Royals recalled RHP Vin Mazzaro from Triple-A Omaha and optioned LHP Tommy Hottovy to the same club. ... LHP Jon Lester (1-2, 4.62 ERA) starts the series finale on Wednesday for Boston. LHP Bruce Chen (0-4, 4.98)) takes the mound for the Royals.