PHILADELPHIA (AP) — Carson Wentz proved to the Philadelphia Eagles in three years he's worth a huge investment.

Wentz and the Eagles have agreed on a four-year contract extension through the 2024 season. The deal announced Thursday night adds four years to Wentz's rookie contract. It's worth $128 million with more than $107 million guaranteed, according to ESPN.

"From the moment I got drafted here, I knew this place was special, I knew they had the most passionate fans in the world, in all of sports, and I knew we had the opportunity to build something truly special and to be cemented here means the world to me," Wentz wrote on Twitter.

Wentz is 23-17 in three seasons as the starting quarterback but has missed 13 games, including five playoff contests over the past two years. He finished third in NFL MVP voting in 2017 when backup quarterback Nick Foles led the Eagles to a Super Bowl victory over the Patriots.

Wentz tore his ACL in Week 13 in 2017 and sat out the final three regular-season games in 2018 because of a back injury. This is only his second full offseason preparing as the starting quarterback. He was No. 3 on the depth chart in 2016 until Sam Bradford was traded a week before the opener.

"It's a huge benefit," Wentz told The Associated Press last week about practicing with the starters throughout the summer.

"Unfortunately injuries happen and sometimes you can't be out there but any chance I can be out there, I want to be. I want to be attacking it full on and building chemistry with these guys. ... Building that chemistry and that foundation this time of year is critically important and it's been fun so far."

Selected No. 2 overall out of North Dakota State in the 2016 draft after Jared Goff, Wentz has thrown for 10,152 yards, 70 touchdowns and 28 interceptions with a 92.5 passer rating. Despite some inconsistency last season, he posted career highs in completion rate (69.6 percent) and passer rating (102.2). His 32 TD passes in 2017 and completion percentage last season are franchise records.

A fierce competitor on the field, Wentz is equally passionate about his charitable work. He launched his Audience of One Foundation after his rookie season and last week hosted his second annual charity softball game with teammates at the home of the Philadelphia Phillie. The event has drawn more than 40,000 fans and raised more than $1.3 million for his charitable initiatives. Those include building a sports complex in Haiti, a 25-foot food truck named "Thy Kingdom Crumb" that delivers free food to people in the Delaware Valley, an ice cream truck that's coming soon and an outdoor youth program — Camp Conquerors — that serves children with physical challenges and life-threatening illnesses.

"We love being a blessing to others and sharing Jesus with people," Wentz said. "These are things I'm really passionate about."

More From 1460 ESPN