Breathe easy, San Francisco 49ers fans: your franchise quarterback isn’t going anywhere.

Mike Garafolo of NFL Network reports that San Francisco and quarterback Jimmy Garoppolo have agreed to a five-year, $137.5 million contract that is the biggest in NFL history in terms of average salary per year.

Garoppolo’s $27.5 million average surpasses the $27 million average in the extension agreed to by the Lions’ Matthew Stafford last year.

Raj Mathai of NBC Bay Area was first to announce the agreement; Garafolo was first with the financial details.

Matt Maiocco of NBC Sports Bay Area has tweeted that the contract includes $74 million in guaranteed money. That is well south of the $92 million guaranteed that Stafford received ($135 million total).

San Francisco 49ers quarterback Jimmy Garoppolo reportedly will sign a five-year extension to remain with the franchise. (AP) More

Of course, it’s unlikely Garoppolo will hold his record for long: Kirk Cousins will likely command more when he finally hits free agency, and Aaron Rodgers will likely get more from the Green Bay Packers on his next deal; his current contract is set to end after the 2019 season.

The 26-year-old Garoppolo was a second-round pick of the New England Patriots in 2014, where he backed up Tom Brady. He did start the first two games of the 2016 season, when Brady was serving his four-game suspension, but didn’t finish the second game after an injury at the hands of Miami’s Kiko Alonso.

New England sent Garoppolo to the 49ers just before the trade deadline last October, receiving a second-round pick in return. After giving him a couple of weeks to acclimate to the playbook, Garoppolo started the final five games of the season, and San Francisco won them all.

His teammates raved about the influence Garoppolo had on the team, and general manager John Lynch made no secret of his desire to make sure Garoppolo’s deal would get done. His rookie contract was set to expire in a few weeks.