The 49ers may have a backup plan in Buccaneers free agent quarterback Mike Glennon if they don’t trade for Kirk Cousins, according to a report from the Sacramento Bee.

If the 49ers can’t land Cousins, they are expected to be one of the teams interested in Tampa Bay free agent Mike Glennon, per multiple sources. Matt Schaub and Brian Hoyer — who, like Cousins, have played for Shanahan in the past — are other possibilities.

It was reported by the NFL Network Friday that Cousins was Kyle Shanahan’s top choice to start at quarterback next season. Cousins was given the franchise tag last week but could still be traded if he doesn’t sign a long-term deal with Washington before the deadline July 15.

Cousins otherwise is expected to hit free agency next spring and could leave while Washington recoups a third-round compensatory selection in the 2019 NFL draft.

Glennon, who lost his starting job when Tampa Bay used the first-overall pick on Jameis Winston in 2015, has also been linked to the Bears and Jets, who both are in the market for starting quarterbacks.

The 27-year-old hasn’t started a game since 2014. Glennon completed 59 percent of his throws in 21 career games, with 30 touchdown passes to 15 interceptions. His passer rating is 84.6.

Some attribute his struggles to playing behind a bad offensive line. Glennon (6-7, 225) was sacked 56 times in his first 19 games. He was selected in the third round of the 2013 draft from North Carolina State.

The 49ers have no quarterbacks on the roster after Colin Kaepernick opted out of his contract last week. Blaine Gabbert, Christian Ponder and Thad Lewis – San Francisco’s quarterbacks from 2016 – are scheduled for free agency when the new league year begins March 9.