The 28-year-old Pineda, who is recovering from Tommy John surgery, will earn $2 million in 2018 and $8 million in 2019, the Twins announced during baseball's winter meetings.
Pineda was placed on the disabled list in mid-July with a right UCL injury and eventually underwent Tommy John surgery on his right elbow on July 18. He likely will not be available for the 2018 season as he continues his rehab but would be ready for spring 2019.
Pineda has played five seasons in the major leagues, spending 2011 with the Seattle Mariners and 2014-17 with the Yankees, combining for a 40-41 record in 117 starts with a 4.05 ERA, 687 strikeouts and 157 walks over 680 innings.
The Dominican Republic native started 17 games for the Yankees last season, going 8-4 with a 4.39 ERA, 92 strikeouts and 21 walks over 96 1/3 innings.
The 6-foot-7, 260-pound Pineda was originally signed as a free agent by Seattle in December 2005. He was named to the American League All-Star team in his rookie season with the Mariners in 2011 and was acquired by the Yankees via trade in January 2012.