|More on Red Sox-Blue Jays|
|More MLB coverage|
Lester came in 4-0 in five starts this month but allowed a season-high six runs and six hits in six innings.
"It was one of those nights for me from pitch one," he said. "I just wasn't able to repeat the ball down in the zone, and that's big. Curveballs just kind of rolled in there and I didn't have a very effective changeup."
Lester had not given up so many runs since the Blue Jays scored 11 times in four innings against him last July 22 at Toronto.
"They've got a quick-strike offense and they swung the bats very well tonight," Red Sox manager John Farrell said of the Blue Jays. "They didn't miss pitches when they got them on the plate."
Red Sox catcher Jarrod Saltalamacchia credited the Blue Jays for grinding out at-bats against Lester.
"They battled every pitch," Saltalamacchia said. "There wasn't too many guys who were swinging at the first pitch, rolling over. They battled, they made him throw."
Toronto ended a four-game losing streak and avoided the first 18-loss April in club history.
"We showed a lot of guts today, a lot of heart," Blue Jays manager John Gibbons said.
David Ortiz homered and drove in four runs for Boston, which had won five in a row and was trying for its first 19-win April.
Ortiz is batting .500 with 15 RBIs in nine games since coming off the disabled list.
"He's just done an outstanding job for us," Farrell said.
Encarnacion's pair of two-run shots marked the 10th multihomer game of his career and second this season. He has nine home runs this year.
"Everybody got excited, everybody was happy after the game," Encarnacion said. "Winning a game like this, that's what we need right now."
Encarnacion became the 14th player to reach the upper deck in left field at Rogers Centre, tagging Lester with a shot estimated at 419 feet. Toronto trailed 7-6 when Encarnacion homered off Junichi Tazawa (2-1).
Toronto opened the scoring in the first on Jose Bautista's RBI double off the center-field wall.
The Blue Jays made it 4-0 with a three-run third, taking advantage of a throwing error by Saltalamacchia. After Toronto loaded the bases, Saltalamacchia tried a pickoff at first, but the ball sailed into right field, allowing two runners to score.
Saltalamacchia said the errant throw was caused by his elbow hitting the facemask of plate umpire Clint Fagan. Fagan told the Red Sox the contact happened on Saltalamacchia's followthrough, and did not rule a dead ball.
"He didn't see it the way we saw it," said Farrell, who came out to discuss the play at the end of the inning.
Saltalamacchia said he's had the same thing happen to him before when trying pickoff throws to first.
"I didn't really make a stink about it because I didn't really know the ruling on it," Saltalamacchia said. "Now I know. Once it hits his mask, it's got to be a dead ball."
Two outs later, J.P. Arencibia hit an RBI double.
Ortiz led off the fourth with his third homer, and Carp added a one-out shot as Boston cut the deficit in half. Dustin Pedroia's RBI single in the fifth made it 4-3.
Encarnacion padded the Blue Jays' lead with his towering drive, the first upper-deck drive in Toronto since Shelley Duncan did it for Cleveland in 2011.
"That was probably the biggest blow of the game for me," Lester said.
Since the stadium opened as SkyDome in June 1989, a total of 17 homers have reached the upper deck. Jose Canseco (three) and Josh Phelps (two) are the only players with multiple fifth-deck shots.
Gomes hit a pinch-hit homer in the sixth, and Boston took advantage of an error to score three times in the seventh against reliever Aaron Loup for a 7-6 edge.
Defensive replacement Munenori Kawasaki threw wide of second on a potential double-play grounder to shortstop and Pedroia walked to load the bases. Ortiz cleared them with a double over Bautista's head in right.
Blue Jays starter Brandon Morrow allowed three runs and six hits in five innings. He struck out seven, including five straight in the first and second innings.
- Red Sox OF Shane Victorino (back) hit off a tee, threw and did other exercises but was held out of the lineup for a fifth straight game. He will swing again Wednesday and could take regular batting practice Thursday, Farrell said.
- Boston activated Hanrahan (right hamstring) off the 15-day DL. Farrell said RHP Andrew Bailey will remain the closer.