Gray is turning Red.

The Cincinatti Reds have completed the protracted acquisition of starter Sonny Gray from the New York Yankees on Monday and signed the Nashville native to a three-year extension with a club option for 2023.

ESPN's Jeff Passan and The Athletic's Ken Rosenthal report that the extension is worth $30.5 million, while the club option for $12 million.

Gray was to be a free agent next fall and has $7.5 million remaining on his current deal. The deal gets the Reds five years of control at a maximum of $50 million.

The 29-year-old Gray spent all of last season with the Yankees after being acquired from the Oakland Athletics two seasons ago. Gray finished with an 11-9 record and a 4.90 earned run average in 30 appearances with 23 starts. In 130.1 innings pitched, Gray struck out 123 batters.

The Yankees acquire prospect Shed Long as part of the trade, but will flip him to the Seattle Mariners.

Long is a 23-year-old who spent last season in Double-A, hitting .261/.353/.412. Centre field prospect Josh Stowers goes the other way.

Left-handed pitching prospect Reiver Sanmartin will also be heading to the Reds.