Sources: Eovaldi's deal with Rangers for 2 years, $34 million

Free-agent pitcher Nathan Eovaldi agreed to a contract on Tuesday with the Texas Rangers, the team announced late in the day.

The deal is for two years and $34 million, and it includes a third-year vesting player option, sources told ESPN's Jeff Passan earlier in the day. Performance bonuses in the contract can take the total value even higher for the veteran.

If Eovaldi reaches 160 innings pitched per season, which he did in 2021, the bonuses could get up to $3 million a year. And the player option features a clause indicating that if he throws 300 innings from 2023 to 2024, a $20 million option in 2025 could kick in, with another $3 million in bonuses. All told, the maximum for his deal is three years and $63 million.

Eovaldi has potential for multiple roles, as he both started and came out of the bullpen last season for the Boston Red Sox. He was Boston's Opening Day starter, in fact, and finished the season at 6-3, with a 3.87 ERA and 103 strikeouts.

Eovaldi, who will turn 33 in February, broke in with the Los Angeles Dodgers in 2011, going 1-2 with a 3.63 ERA. He pitched for the Miami Marlins, New York Yankees and Tampa Bay Rays before landing with the Red Sox in 2018, helping them win the World Series that fall.

Last season was his fifth in Boston, and it was interrupted by injury. He left the active roster on June 9 with lower back inflammation and didn't return until mid-July. The right-hander was 4-2 with a 3.16 ERA in 12 starts before getting hurt.

His best season with Boston came in 2021, when he was 11-9 with a 3.75 ERA and 195 strikeouts. His career high for wins (14) came with the Yankees in 2015.

Even before Eovaldi's deal, the Rangers had remade their rotation this offseason. Earlier this month, they agreed to terms on a two-year deal with free-agent starter Andrew Heaney not long after striking a five-year deal with Jacob deGrom. The staff also includes holdovers Jon Gray, Jake Odorizzi and Martin Perez.

Last season, Texas went in a different direction and added high-profile offense to its mix. The Rangers spent a combined $500 million on middle infielders Corey Seager and Marcus Semien only to finish 68-94 in the American League West.