FOXBORO, Mass. - With just under three minutes remaining Sunday, the league's No. 1 scoring offense needed a touchdown against the No. 1 scoring defense.
The defense won.
Without anchor and ironman Justin Smith, the 49ers held Tom Brady and the Patriots to a four-and-out deep in their own territory. That led to a short David Akers field goal that ended up being the game-sealing score in a wild and wet 41-34 victory that saw San Francisco blow a 28-point lead in the third quarter and then win it back again at the end.
With the victory, the 49ers guaranteed themselves at least a spot in the playoffs. If they beat the Seahawks - blowout winners against Buffalo on Sunday - next week in Seattle, they will win the NFC West for the second straight season.
"It's not the playoffs, but it was a playoff environment," cornerback Carlos Rogers said afterward. "We know the next couple of games are going to be like that."
For most of the night the storyline was the way Colin Kaepernick, making just his fifth career start, outplayed veteran and NFL poster boy Tom Brady. Kaepernick finished with four touchdown passes, including a 38-yard catch and run by Michael Crabtree late in the fourth quarter that recaptured the lead and put the 49ers ahead for good.
That score was set up by a 62-yard kickoff return by rookie LaMichael James, which may have been the game's most pivotal play. "He did a great job staying in bounds, it looked like from my perspective," Jim Harbaugh said after the game. "Tremendous run. Huge play in the game."
Brady, meanwhile, threw two interceptions after being picked off only four times in the first 14 games. Still, he engineered a furious comeback during the fourth quarter that saw the Patriots tie the game at 31 with 6:43 remaining. Brady threw 40 more passes than Kaepernick and finished with 443 yards. But the 49ers held him to a pedestrian 68.9 passer rating, and their nickel defense gave the Patriots quarterback fits throughout the game.
"I knew he attempted a lot (of passes)," Rogers said. "Once they got behind, we knew it was going to be seven-on-seven the rest of the game. We knew we just had to man up and stop them."
The Patriots had only 10 turnovers through the first 14 games, but four on Sunday as the 49ers defense ripped, tipped and yanked away the ball during the first half and third quarter.
Rogers came down with Brady's first-quarter bomb to Wes Welker and returned it 53 yards to the New England five-yard line. Rogers tied for the team lead in interceptions last year with safety Dashon Goldson, but he hadn't had any before Sunday.
Aldon Smith, who is now tied for the lead league in sacks with Houston's J.J. Watt, had no sacks. But he did hit Brady two times and came up with a tipped pass for an interception in the third quarter. The 49ers scored on the next play, a 27-yard pass from Kaepernick to Crabtree.
The 49ers also forced Patriots running backs to fumble twice, once on a hit by NaVorro Bowman, the other by Donte Whitner. Goldson returned the Whitner-forced fumble 66 yards to the Patriots 3-yard.
The 49ers played without the anchor of their defensive line, Justin Smith, beginning in the third quarter. Smith had started 188 consecutive games, the longest streak for a defensive lineman. But he injured his elbow as Brady and Patriots began their comeback. Smith had the arm wrapped, and he tried to return to the game but found his arm was not responding.
The 49ers said Smith would have an MRI on Monday. "No word yet," Harbaugh said when asked about the lineman's prognosis.
Smith's primary backup, Demarcus Dobbs, was placed on injured reserve last week. Instead Ricky Jean Francois filled in and ended up getting one of the three sacks on Brady. Defensive end Ray McDonald had the other two.
After the game, Harbaugh likened the way the 49ers responded to the big, prime-time game to his childhood growing up near a railroad station. If you play in enough momentous games, Harbaugh said, they won't phase you.
"The more you hear the train," he said, "the less you hear it."
-- Matt Barrows