The winning drive began after the 49ers failed on a fourth-and-1 at the Baltimore 35, when Jimmy Garoppolo had a pass deflected at the line of scrimmage. San Francisco (10-2) lost for the second time in its last four games after an 8-0 start.
Texans 28, Patriots 22
Deshaun Watson passed for three touchdowns and added a receiving touchdown as host Houston defeated New England, giving the Texans their first victory over the Patriots since Week 17 of the 2009 season.
The Texans (8-4) maintained their one-game lead in the AFC South and handed the Patriots their second loss in 12 games this season. New England had been 10-1 all-time against Houston, including postseason play, with five wins over the previous four seasons.
Watson, who finished 18 of 25 for 234 yards, became the first quarterback to throw two scoring passes against the Patriots this season. Patriots quarterback Tom Brady completed 24 of 47 passes for 326 yards and three touchdowns -- two in the final four minutes as New England mounted a late charge that fell one drive short.
Chiefs 40, Raiders 9
Quarterback Patrick Mahomes passed for just 175 yards in windy conditions, but host Kansas City relied on a stubborn defense to stomp Oakland.
The victory widened the advantage the Chiefs (8-4) enjoy in the AFC West, as the second-place Raiders fell to 6-6. Quarterback Derek Carr managed just 222 yards passing for the Raiders, who suffered consecutive 30-point losses for the second time in franchise history and the first since 1961. They fell 34-3 last week to the New York Jets.
The sub-200 yard performance was the second straight for Mahomes, who went 15 of 29 with a touchdown. The need for offensive production was minimized by three takeaways generated by Kansas City, including an interception returned for a touchdown by rookie safety Juan Thornhill.
Packers 31, Giants 13
Green Bay rebounded from an awful loss to the San Francisco 49ers and handed New York its eighth consecutive loss in East Rutherford, N.J.
Packers quarterback Aaron Rodgers, coming off one of the worst games of his career, threw four touchdown passes. Giants rookie quarterback Daniel Jones, on the other hand, tossed three interceptions.
Jones, the sixth pick of the draft, won his first two starts in place of Eli Manning but has dropped eight straight. After throwing 11 touchdown passes vs. one interception in his last four starts, Jones was back to his error-prone self. While he didn't add to his league-worst figures of 14 fumbles and 10 lost fumbles, he threw interceptions to cornerback Kevin King, safety Darnell Savage and slot Tramon Williams.
Bengals 22, Jets 6
Cincinnati earned its first win of the season as Andy Dalton returned to the starting lineup and threw for 243 yards and one touchdown in a victory over visiting New York.
The win ended the longest season-opening losing streak in franchise history for the Bengals (1-11) and ensured they would not join the 2008 Detroit Lions and 2017 Cleveland Browns as the only teams to go winless over a 16-game season.
The Jets (4-8) not only had a three-game winning streak snapped but also made the wrong kind of history Sunday, when they became the first NFL team to lose twice to teams that were 0-7 or worse entering the game. The Miami Dolphins were 0-7 before beating New York 26-18 on Nov. 3.
Dolphins 37, Eagles, 31
Quarterback Ryan Fitzpatrick threw for 365 yards and three touchdowns, and Miami scored 23 consecutive points to defeat visiting Philadelphia.
Fitzpatrick completed 27 of 39 passes and rallied the Dolphins (3-9) from a 28-14 deficit. Wide receiver DeVante Parker had seven catches for a career-high 159 yards and two scores.
Philadelphia quarterback Carson Wentz was 28 of 46 for 310 yards and three touchdowns, but the Eagles dropped their third in a row and fell to 5-7.
Steelers 20, Browns 13
After a slow start, quarterback Devlin "Duck" Hodges, and Pittsburgh came on to beat visiting Cleveland.
Hodges, an undrafted third-stringer who was given the start over Mason Rudolph, was 14-of-21 passing for 212 yards, an interception and a touchdown to James Washington (four catches, 111 yards) as Pittsburgh (7-5) erased a 10-0 deficit. Benny Snell added a touchdown run.
Cleveland's Baker Mayfield passed for 196 yards, with a touchdown to Kareem Hunt and an interception. He was sacked five times.
Titans 31, Colts 17
Tye Smith returned a blocked field goal 63 yards to snap a fourth-quarter tie, and Ryan Tannehill added his second touchdown pass two minutes later, as visiting Tennessee rallied for a win over Indianapolis.
The Titans (7-5) won for the fifth time in six games, avenging a September home loss to the Colts (6-6), and stayed within a game of Houston for first place in the AFC South.
With the game tied at 17, Adam Vinatieri tried a 46-yard field goal to put Indianapolis ahead. But Dane Cruickshank surged through the right side to snuff the kick, and Smith sprinted untouched to the end zone with 5:02 left. It was the second field-goal attempt blocked by Tennessee in the game.
Rams 34, Cardinals 7
Jared Goff threw for 424 yards and connected on his first touchdown pass in over a month, as visiting Los Angeles boosted its shrinking playoff hopes by rolling to a victory over Arizona.
Goff threw two touchdowns on the day, his first scoring strikes since Oct. 27 in a victory over the Cincinnati Bengals in London. Tight end Tyler Higbee and wide receiver Cooper Kupp caught scoring passes as the Rams (7-5) rebounded from a demoralizing 45-6 defeat to the Baltimore Ravens on Monday night.
Cardinals rookie quarterback Kyler Murray was 19 of 34 for 163 yards, was sacked six times and threw an interception that was returned for a touchdown by Rams rookie safety Taylor Rapp. The Cardinals (3-8-1) were held to 63 total yards in the first half and 198 in the game while losing for the fifth consecutive time.
Broncos 23, Chargers 20
Brandon McManus kicked a game-winning 53-yard field goal as time expired, and rookie quarterback Drew Lock passed for two touchdowns in his NFL debut to lift host Denver to a victory against Los Angeles.
The Broncos (4-8) snapped a two-game losing streak and swept the season series, while the Chargers (4-8) lost their third straight.
McManus' field goal followed a 37-yard pass interference penalty against the Chargers on a play that began with just nine seconds remaining. It was the third field goal in the game's final 4:26.
Buccaneers 28, Jaguars 11
Linebacker Devin White intercepted a pass to set up a score and then returned a fumble for a touchdown, as visiting Tampa Bay built a 25-point halftime lead and held off Gardner Minshew-led Jacksonville.
Rookie quarterback Minshew replaced Nick Foles at the start of the second half, with the Jaguars down 25-0. Foles was 7 of 14 for 93 yards with one interception and two lost fumbles, with the three turnovers leading to 22 Buccaneers points.
Jameis Winston was 21 of 33 for 268 yards for the Bucs (5-7). Minshew finished 16 of 27 for 147 yards, one TD and one interception for the Jaguars (4-8), who were penalized 16 times for 125 yards.
Redskins 29, Panthers 21
Derrius Guice rushed for two touchdowns, and Washington came up with a late goal-line stand in a victory against host Carolina in Charlotte, N.C.
The Redskins (3-9) won for the second week in a row, and they didn't allow a point for a 48-minute stretch until the game's final two minutes. Guice gained 129 yards on 10 carries. Teammate Adrian Peterson picked up 99 rushing yards on 13 attempts, including a 12-yard touchdown run with 4:26 to play.
Panthers quarterback Kyle Allen scrambled 17 yards for a touchdown with 1:51 remaining on a drive extended because of a fourth-down conversion. Carolina recovered the ensuing onside kick and reached the Washington 1 for a first down before running back Christian McCaffrey lost yards on consecutive plays, followed by an incomplete pass and a sack.