Kaepernick faked an inside handoff and then threw a short sidearm pass to Quinton Patton, who deked rookie free agent Marcus Cromartie and completed the 43-yard scoring play.
Predicting the 2013 NFL season
Kaepernick completed 3 of 4 passes for 64 yards for a rating of 156.2, which is nearly perfect. He didn't have any carries.
"Everything seemed to be happening the right way," Johnson said.
On the blocked punt, "I went after the ball and got a hand on it. I was looking around for it. I saw it rolling around in the end zone and jumped on it. I had no idea where it rolled."
"I don't think there were a whole lot of positives," McCoy said. "This is a tough way to finish, to be honest with you. It is a bad taste. You never feel good after a loss, regardless of what kind of game it is. We didn't play very well today. We made way too many mistakes; offense, defense, special teams. We have to learn and move on.
The Chargers, who've missed the playoffs for three straight seasons, open at home against Houston a week from Monday.
Niners free-agent pickup Lavelle Hawkins had a spectacular 45-yard touchdown play in the fourth quarter.
"He stayed with it and had the awareness enough to catch it and make a play and make a couple guys miss and score a touchdown," Daniels said.
"When I took the first hit I was bounced back," Hawkins said. "I don't know what I was thinking after that. I was just running, man."
With Harbaugh playing his starters, the mismatch paid off as the 49ers moved 77 yards in seven plays for the score.
McCoy completed 8 of 15 passes for 56 yards.
Daniels also threw a 15-yard touchdown pass to rookie Chuck Jacobs. Daniels had a 36-yard run on that drive.
Whitehurst was 9 of 12 for 86 yards, with one interception. Max Starks, who apparently has lost the competition for the starting job at left tackle to King Dunlap, was repeatedly beaten and gave up three sacks. The other sack was allowed by right tackle Mike Harris, who played left tackle last year as a rookie.
Chargers rookie linebacker Manti Te'o was back in his walking boot as he watched the game from the sideline in a sweatsuit. Te'o sprained his right foot in the exhibition opener against Seattle on Aug. 8. Te'o said being back in the boot was a precaution. He was out of the boot Tuesday, although he hasn't been cleared to practice.
NOTES: Scifres hobbled off the field after having the punt blocked, but said he was OK. ... McCoy said there's clarity as to who will start at left tackle, but he wants to speak with his staff before making a final commitment. ... Harbaugh says Seneca Wallace, at the bottom of the depth chart at quarterback, has left the team. Wallace didn't travel to San Diego.
Copyright 2013 by The Associated Press