PITTSBURGH -- A.J. Burnett is back with the Pittsburgh Pirates.

The pitcher agreed Friday to an $8.5 million, one-year contract -- $4.25 million less than the player option he turned down with Philadelphia.

A 37-year-old right-hander, Burnett went 26-21 with a 3.41 ERA for Pittsburgh in 2012-13, helping the Pirates return to the postseason in 2013 following a 21-year drought.

He spurned an offer from Pittsburgh last offseason and eventually signed with Philadelphia, where he went 8-18 with a 4.59 ERA in 34 starts. His 18 losses led the majors.

Burnett and the Phillies both declined a $15 million mutual option, and the pitcher then turned down his player option.

Pittsburgh needed insurance for a rotation that could lose Francisco Liriano and Edinson Volquez in free agency.