BUFFALO, N.Y. - Gerrit Cole limited the Toronto to five hits over seven innings in his final preparation for the playoffs, and Aaron Hicks drove in three runs in a 12-1 rout over the Blue Jays on Tuesday night.

Cole (7-3) struck out seven and walked none, inducing 11 ground-ball outs and 14 swings and misses. His one mistake was Cavan Biggio's sole homer in the fourth.

Cole finished his first season with the Yankees with a 2.84 ERA and 94 strikeouts in 73 innings after signing a $324 million, nine-year contract as a free agent with the team he rooted for growing up.

He allowed three earned runs in his last 27 innings, dropping his ERA from 3.91 at the end of August after the second of three straight losses that followed 20 consecutive winning decisions.

Cole's surge coincided with the Yankees moving Kyle Higashioka behind the plate for his last four starts. Cole had a 1.00 ERA while pitching to Higashioka (three earned runs in 27 innings) and a 3.91 ERA while pitching to Gary Sanchez (20 earned runs in 46 innings).

Aaron Judge, in a 2-for-17 slump since coming off the injured list, had his first three-hit game since Aug. 8 and the Yankees improved to just 2-10 when not homering. New York had 15 hits and went 8 for 10 with runners in scoring position.

Gio Urshela had four hits and Gleyber Torres had three hits and two RBIs. New York has won 11 of 13 following a 5-15 slide.

New York lowered its magic number to one for clinching second place in the AL East. The Yankees (32-23) are chasing Minnesota (33-22) for the No. 4 seed in the AL and home-field in the first round of the playoffs.

Biggio hit his seventh homer and reliever Chase Anderson struck out five for Toronto (28-27), whose magic number to clinch a playoff spot remained at three.

Hicks drove in a run in the first with his second triple this season and added a two-run single in the fifth. He is batting 225, his highest average since before play on Aug. 18.

The game was delayed in the eighth inning when the Yankees brought in Tyler Lyons, whose contract was selected from the alternate training site earlier Tuesday. Umpires sent Lyons back to the dugout, forcing New York to utilize Zack Britton with an eight-run lead.

Tanner Roark (2-3) allowed six runs and seven hits in 4 1/3 innings.

BATTING TITLE

DJ LeMahieu went 0 for 3 and his league-leading average dropped to .356. Chicago's Tim Anderson is second at ,353 after going 1 for 4 against Cleveland. LeMahieu won the NL batting title in 2016 and would join Ed Delahanty, as the only batting champion in the AL and NL, according to the Elias Sports Bureay. Delahanty won with Philadelphia in 1899 and Washington in 1902. LeMahieu would be the Yankees' first batting champ since Bernie Williams in 1998.

MAKING MOVES

The Yankees optioned RHP Michael King to their alternate training site, following his start on Monday in which he struck out six but allowed five runs in 2 2/3 innings. RHP Ben Heller was recalled and put on the 60-day IL with a right biceps nerve injury.

TRAINER'S ROOM

Blue Jays: RHP Nate Pearson (elbow) appears to be getting closer to being activated before the season ends on Sunday. ... RHP Jordan Romano (strained right middle finger) threw a bullpen session with nearly the entire Toronto pitching staff watching. ... INF Travis Shaw was in the original lineup, then removed due to back spasms. ... RHP Rafael Dolis (right knee discomfort) was unavailable and remains day to day.

UP NEXT

Yankees RHP Masahiro Tanaka (3-2, 3.27) will face Blue Jays LHP Robbie Ray (2-5, 7.17) on Wednesday. Tanaka worked a season-high seven innings in his last start, also against Toronto. Ray, acquired Aug. 31 from Arizona, will be making his fifth appearance with the Blue Jays.