9:22 AM ET

The Detroit Tigers have agreed to a six-year, $140 million deal with free-agent shortstop Javier Baez, a source told ESPN's Buster Olney on Tuesday.

The deal also includes an opt-out, according to the source. It would be the second-largest free-agent deal in Tigers franchise history. (Prince Fielder signed a nine-year, $214 million deal with Detroit in January 2012.)

While he struck out a league-high 184 times last season, Baez hit .265 with 31 homers, 87 RBIs and 18 steals. He also brings Gold Glove defense to Detroit with his signature no-look tags.

The Cubs selected Baez in the first round of the 2011 draft. The two-time National League All-Star had been close to signing a long-term extension with Chicago before the 2020 season, but the COVID-19 pandemic put negotiations on hold.

Those contract talks never resumed, and the Cubs traded Baez to the Mets this past July.

ESPN's Jesse Rogers contributed to this report.