Adam Schefter explains how the Jets and quarterback Ryan Fitzpatrick were able to come to terms on a one-year contract worth $12 million of guaranteed money. (1:43)

How did Fitzpatrick's deal with the Jets come together? (1:43)

The New York Jets and quarterback Ryan Fitzpatrick ended their five-month contract dispute Wednesday. The two sides finalized a one-year, $12 million contract on the eve of the team's first training camp practice, sources told ESPN.

Another $3 million in incentives are included in the deal, which could boost the value to $15 million, a source told ESPN NFL Insider Adam Schefter.

The Jets increased their offer Wednesday from $9 million to $12 million, a source said, and gave Fitzpatrick until 7 p.m. ET to take the deal or the team would be "moving on."

The 11th-hour agreement culminated one of the strangest chapters in team history -- a long stalemate that dominated the Jets' offseason.

The Jets wanted Fitzpatrick and he wanted them, yet he refused to sign the offer that sat on the table for months -- three years, $24 million, including a total guarantee of $16 million.

"It definitely was a long process," Fitzpatrick said Thursday. "After coming to the realization that it wasn't going to get done right away and that it was going to take some time, I tried my best to put it out of my mind and tried to live life normally. But it was hard with people coming up to me and asking about the contract, people texting me. It was hovering ... looming over my head for five, six months. In the end, I'm happy the way it turned out."

To make the Fitzpatrick signing official, the Jets will have to create room under the salary cap. They have only $9.1 million in cap space, according to NFL Players Association records.

Ryan Fitzpatrick threw for a career-high 31 touchdowns and 3,905 yards last season as the Jets' quarterback. Tom Szczerbowski/Getty Images

The situation got weird Wednesday, when players said they were instructed by team brass not to discuss Fitzpatrick with the media.

After sitting out the offseason, Fitzpatrick is way behind, but he is expected to be the opening day quarterback. Jets coach Todd Bowles maintained throughout the stalemate that Fitzpatrick, who set a franchise record with 31 touchdown passes last season, would be the starter if he re-signed.

Geno Smith, who was replaced by Fitzpatrick last preseason after having his jaw broken by a teammate's sucker punch in the locker room, returns to his No. 2 role. Rookie Christian Hackenberg and second-year quarterback Bryce Petty will compete for the No. 3 job, although it's possible the Jets will keep all four quarterbacks on the 53-man roster.

Fitzpatrick had no other offers during free agency, yet the Jets were reluctant to hand the No. 1 job to Smith, the nominal starter in the offseason. The result was a staring contest, with each side waiting for the other to blink.

Knowing his comfort level with the coaches, the players and the city, the organization was quietly confident it would re-sign Fitzpatrick, 33, a career journeyman who last season led the Jets to their best offensive season since 1998. He became a popular leader in the locker room, fueling a pro-Fitzpatrick sentiment throughout the impasse.

Several players, namely wide receivers Brandon Marshall and Eric Decker, were outspoken in their support for Fitzpatrick, perhaps putting pressure on the organization to complete a deal. Team officials were transparent, saying from the outset they wanted him back.

Marshall took to Twitter to congratulate Fitzpatrick, posting a photo presumably shot after the quarterback's deal was agreed to Wednesday.

Fitzpatrick was stung by the team's contract proposal, telling friends he would never accept a deal that included a total of $12 million in the second and third years -- essentially backup money. The offer included up to $12 million in incentives, but he didn't bite. He made $3.25 million last season.

He didn't renew the lease for the New Jersey home he rented last season, fueling speculation about his future. He also stopped returning texts from teammates, according to Marshall, who said he was starting to worry.

As much as they appreciate his 2015 performance, the Jets view Fitzpatrick as a "bridge" quarterback, a caretaker until Hackenberg or Petty is ready to take over. That led to a sharp difference of opinion at the bargaining table. Fitzpatrick initially sought $15 million per year, as he tried to piggyback on the Sam Bradford and Brock Osweiler deals with the Philadelphia Eagles and Houston Texans, respectively.

The Jets flirted with free-agent quarterbacks Robert Griffin III and Brian Hoyer, but talks never reached the serious stage.

Fitzpatrick, playing for his sixth team, arrived last year in a trade with the Texans. His career record as a starter is 43-61-1 in 11 seasons with no playoff appearances. He was on the verge of breaking the postseason slump last year, but he tainted his storybook season by throwing three interceptions in a season-ending loss to the Buffalo Bills.