Ricky Romero was hoping his final start of the year would help erase some of the memories from a disappointing regular season.
Instead, the Toronto left-hander had to deal with even more frustration as a left leg injury ended his day after just three innings.
The Blue Jays' bullpen picked up Romero with six innings of shutout relief and Rajai Davis homered as Toronto (70-88) came back to defeat New York 3-2 at Rogers Centre.
The Baltimore Orioles later beat Boston 4-3 to tie the Yankees atop the American League East.
Toronto manager John Farrell said Romero was pulled as a precaution after he experienced discomfort in the area just above his left kneecap.
After talking to Farrell and a team trainer during the third inning, Romero threw a few warmup pitches and stayed in the game. He got the final two outs but didn't return for the fourth.
"He didn't want to come out of the ball game," Farrell said. "Even after the inning was over, he still wanted to stay in. But it was evident by the additional pitches that he threw after checking him that he didn't feel any discomfort, (and I) left him in to finish the inning.
"But after that it was clear that it wasn't something that we were going to push."
Romero wasn't available for comment after the game. A team spokesman said he was undergoing medical tests.
Romero later tweeted his disappointment with the game and season.
"I put my heart and soul to baseball and push my body to the limit every year. I expect so much outta myself year in & year out. I'm really Sad and disappointed the way my year went and ended. To the fans that stuck with me all year thank u for all ur support."
Canada's Shawn Hill (1-0) replaced Romero and threw three hitless innings for the win. Three relievers followed before Casey Janssen recorded the final three outs for his 21st save.
"An outstanding job by the bullpen today," Farrell said.
Yunel Escobar trotted home from third base with the go-ahead run in the sixth inning when Adeiny Hechavarria hit a two-out double off the right-field wall. New York (91-67) needs a win in Sunday's series finale to salvage a split of the four-game set.
Romero started off slowly on a chilly, overcast afternoon by loading the bases with nobody out in the first inning. The Yankees scored both of their runs in the frame on sacrifice flies.
Davis answered in the bottom half with a solo shot that barely cleared the wall in left field. It was his eighth home run of the season.
Romero loaded the bases again in the third before recording an out. He got out of the jam with a flyout, strikeout and lineout.
"We had plenty of opportunities today to get some runs and we just didn't get it done," said Yankees manager Joe Girardi. "We have to take advantage of some opportunities and we didn't do it today."
Romero appeared to hurt himself on a pitch to Andruw Jones that was well outside. He hopped a few times on the mound and appeared to favour his left side.
The Blue Jays scratched out a run in the fifth inning to tie the game.
Jeff Mathis opened with a double and moved to third on a grounder by Hechavarria. Mathis scored on an infield single by the speedy Davis, who had three of Toronto's seven hits.
The injury capped a very challenging season for Romero, who finishes with a poor 9-14 record and a bloated 5.77 earned-run average. He recorded a win over Baltimore earlier in the week that halted a 13-game losing streak over 15 starts that dated back to June 22.
"It's unfortunate but he did last the whole season," Davis said of Romero. "He's been there since Day 1 and that in itself is outstanding. He was able to eat a lot of innings up for us. Regardless of how well he's pitched — I'm sure everyone wants to do better — but he was able to give us innings and that's what he did."
Romero allowed two earned runs, six hits and two walks. He had three strikeouts and threw 38 of his 63 pitches for strikes.
Yankees starter Andy Pettitte (5-4) worked five-plus innings and gave up three earned runs and five hits. He walked three batters and had four strikeouts.
Notes: Announced attendance was 36,139, which pushed the season total at Rogers Centre past the two-million mark at 2,022,187. ... The game took two hours 54 minutes to play. ... Hill became the 54th different player to suit up for the Blue Jays this season. That breaks the former club record of 53 set in 2011 and 1999. ... Henderson Alvarez (9-14) will get the start for Toronto on Sunday. The Yankees will counter with Phil Hughes (16-13). ... The Blue Jays will close out the regular season with a three-game series against the Minnesota Twins next week.