The Yankees won their fifth in a row in a late-season playoff push and completed a four-game sweep of the Blue Jays. New York has won each of its last 13 meetings with Toronto in Yankee Stadium.
Pettitte (9-9) gave up four hits and walked three, helping New York climb within 3 1/2 games of Oakland for the second American League wild card berth.
New York scored all its runs in the fifth and sixth innings, benefiting from five walks in those two frames. Curtis Granderson hit a solo homer in the two-run fifth and Eduardo Nixon highlighted the sixth with a two-run single. Both the runners Nixon drove in had reached on walks.
The loss went to J.A. Happ (3-3), who gave up four runs in 5 1/3 innings.
With closer Mariano Rivera having thrown 2 2/3 innings in their previous two games, the Yankees called on David Robertson to finish off the Blue Jays in the ninth. Robertson did not allow a runner in picking up his second save.