SANTA CLARA, Calif. — Jimmy Garoppolo and the San Francisco 49ers bounced back from a lopsided loss and showed the banged-up defending NFC champions aren't ready to pack it in quite yet.

Garoppolo threw three TD passes in the first half and Jason Verrett’s first interception in more than four years helped preserve the lead, giving the 49ers a 24-16 victory over the Los Angeles Rams on Sunday night.

“Whenever you get embarrassed like we did last week you can find out a lot about your team,” coach Kyle Shanahan said. “Usually when stuff like that happens, guys either give in and try to hide or guys try to step up and get better.”

Garoppolo got pulled at halftime last week in a 43-17 loss to Miami after struggling on a bum ankle, raising questions if the injury-riddled Niners (3-3) would be able to contend in the NFC West after back-to-back home losses to the Dolphins and Philadelphia.

But Garoppolo staked the Niners to a 21-6 halftime lead over the Rams (4-2) by relying mostly on short passes and connecting on TDs with Deebo Samuel, George Kittle and Brandon Aiyuk.

“It was a different mindset that everyone had,” Garoppolo said. “The couple of weeks before that, no one like that feeling. It wasn’t who we are as a team. This week got us back on track.”

San Francisco’s defence stepped up with some key stops in the second half. Los Angeles got in the red zone on its first possession of the third quarter, but settled for a field goal after Andrew Whitworth committed a false start on third-and-1.

The Rams were in position to cut even more into the deficit before Dre Greenlaw stopped Darrell Henderson for a 1-yard loss on second-and-goal from the 1, Cooper Kupp dropped a pass in the end zone on third down and Verrett came up with the interception on fourth down.

“We just got back to playing like we know how to play,” defensive lineman Arik Armstead said.

Verrett has ended up on injured reserve in five of his six seasons in the NFL and played only 66 defensive snaps the past three years. But he has gotten back to his 2015 Pro Bowl level this season for the 49ers, helping fill the void created by an injury to Richard Sherman.

Verrett's interception was part of a rough day overall for Jared Goff, who also missed an open Kupp on a deep ball earlier in the second half. Goff went 19 for 38 for 198 yards with two touchdowns and one interception.

“Offensively, we just were never able to really get any sort of continuity,” coach Sean McVay said. “We had a lot of missed opps (sic). As a whole, just too many things that we’re not accustomed to doing. You give credit to the Niners, they did a nice job, but we had a lot of our players that we count on that didn’t come through in situations that they typically do.”

Garoppolo was unable to keep up his fast start to the game but still finished 23 for 33 for 268 yards.

OUT OF AIR

The 49ers didn’t exactly air it out on the opening drive with all four of Garoppolo’s passes being thrown behind the line of scrimmage. Two were glorified handoffs that counted as passes because the receiver was running in front of Garoppolo and Samuel took one 35 yards and then scored a 6-yard TD on the other. Garoppolo had minus-20 air yards on the drive with 89 yards coming after the catch.

GO FOR IT

One week after getting stopped on an early fourth-and-1 gamble, the Niners converted in a big way. Garoppolo found Kittle on a one-on-one matchup with Darious Williams on a fourth-and-2 play that turned into a 44-yard TD.

BLOCKED

Rams kicker Samuel Sloman’s extra point attempt after Goff’s 10-yard TD pass to Robert Woods in the second quarter was blocked by Dion Jordan. That is the third missed PAT this season for Sloman, tied with Kansas City’s Harrison Butker for the most in the NFL. The last Rams kicker to miss three extra points in a season was Mike Lansford in 1988.

FRED DEAN TRIBUTE

The 49ers wore a decal on their helmets to honour Hall of Fame pass rusher Fred Dean. He died this week after contracting the coronavirus.

INJURY REPORT

49ers: RB Raheem Mostert (ankle) S Jaquiski Tartt (groin) and C Ben Garland (calf) all left in the second half and didn't return.

UP NEXT

Rams: Host Chicago on Monday, Oct. 26.

49ers: Visit New England on Sunday.

___

More AP NFL: https://apnews.com/NFL and https://twitter.com/AP_NFL