Versatile free agent Eric Sogard, who played five different positions in the field last season, has reached a one-year deal with the Milwaukee Brewers, a source confirmed to ESPN on Wednesday.

The deal is for $4.5 million, a source told ESPN’s Buster Olney, includes a team option for 2021 and is pending a physical, a source said. The Athletic first reported the agreement.

Sogard, whose career was in jeopardy after an atrocious 2018 season, rebounded with a career year in 2019 with the Toronto Blue Jays and the Tampa Bay Rays. He hit a combined .290 with 13 home runs and 40 RBIs in 110 games for the two teams.

Known primarily as a second baseman, Sogard can play every infield position as well as corner outfield.

He signed a minor league deal with the Blue Jays prior to the 2019 season, earning a return trip to the majors in mid-April. After hitting just 11 home runs in seven-plus MLB seasons, Sogard went on a tear for Toronto, hitting 10 in just 73 games with a substantially increased launch angle.

Sogard was dealt to the Rays before the trade deadline in late July, and the 33-year-old hit .266 and added three more homers down the stretch — more than doubling his career total in just one season — as Tampa Bay earned an AL wild-card spot.

He excelled as a utility man with the Brewers in 2017, but his future was unclear after he hit just .134 with two RBIs in 55 games in 2018.

Sogard, who spent six-plus seasons with the Oakland Athletics before joining the Brewers in 2017, has a .248 career batting average with 24 home runs and 165 RBIs. He missed the entire 2016 season after having surgery on his left knee.

ESPN’s Jesse Rogers, Keith Law and Jeff Passan contributed to this report.