By Sam McPherson

It wasn’t easy, but the San Francisco 49ers broke their four-game losing streak with a 25-20 win over the Baltimore Ravens on Sunday. The whole team contributed to this win. The offense moved the ball well through the air, the defense bent a lot, but didn’t break often, and the special teams came through big. Overall, this was the best 49ers performance since Week 1—incidentally, the only other S.F. win this season, also at Levi’s Stadium.

Clearly, the 49ers are much more comfortable at home than they are on the road. In three home games, the team is 2-1 while allowing just 40 points total; on the road, San Francisco is 0-3 and giving up 40 points per game. That’s a significant difference that the coaching staff will have to address, but for now, the 49ers can enjoy their second win of the season knowing they’re just two games behind the Arizona Cardinals in the NFC West.

Offense: B

Quarterback Colin Kaepernick had a superb game, the kind the team and its fans wishes he could have every week. By throwing for 340 yards, two touchdowns and no turnovers, the 49ers QB turned in his second straight good performance this season. The S.F. offense only notched 15 first downs the whole game, however, and the 49ers had to settle for four field goals—including two from inside the red zone. There’s room for improvement with Kaepernick still, always, but this was a very good day for him nonetheless.

The running game didn’t really get going in this game, as the 49ers averaged just 2.6 yards per carry; that also hurt the offense’s ability to close out drives with TDs. However, running back Carlos Hyde was not at 100 percent; his 55 yards on the ground were good enough. The deep passing game made up for it in this one, as four receivers averaged at least 19 yards per catch. Former Ravens wideouts Anquan Boldin and Torrey Smith combined for eight catches, 198 yards and a TD against their former team, while fullback Bruce Miller had 89 yards on his three receptions. WR Quinton Patton scored a TD and gained 38 yards on his two catches.

Defense: C+

The defense did get shredded again by a veteran QB, but this time, the 49ers were able to intercept two passes—and they held on the final drive for the opponent, unlike last week against the New York Giants. However, giving up 420 total yards and 343 through the air is not a recipe for consistent success in the NFL. The 49ers know this, obviously, but they’ll take the win nonetheless.

Any football fan knows Joe Flacco is not on par with the other Super Bowl-winning QBs the 49ers have faced this year, yet he still found massive gaps in the S.F. secondary. The key was those turnovers, and the 49ers really didn’t give up any long, back-breaking plays. They also held the Ravens running game to just 3.5 yards per carry. Sure, Baltimore’s offense held the ball for 33 minutes of game time, but in the end, the 49ers defense held just enough.

Special Teams: B

What can you saw about kicker Phil Dawson? He nailed four field goals, and that was the difference in the game. Dawson opened the scoring with a 53-yard FG, and after the two drives into the red zone stalled, he also hit the short ones. In the second half, his 42-yard FG turned out to be huge when the 49ers missed the two-point conversion on their final TD. That meant Baltimore had to drive the length of the field at the end of the game, instead of just needing a field goal to win.

The punting was adequate, and the return game was non-existent. Those areas always can use improvements, of course.

Coaching: A

This is a symbolic grade, as the 49ers have plenty of areas still needing improvement. Busting a four-game losing streak, though, deserves some acknowledgement. The S.F. squad clearly plays better at home, and that’s a credit to the coaching staff—and the fans—for getting this team ready each time it takes the field at Levi’s Stadium. Now, Head Coach Jim Tomsula and friends just need to make sure the 49ers show up for their next road game (at St. Louis on November 1).

Back In The Thick Of The Playoff Chase?

Here’s the skinny: The 49ers and the Seattle Seahawks are tied for last place in the NFC West with identical 2-4 records, and they play on Thursday night at Levi’s Stadium. This is a clear test for the San Francisco organization, as the Seahawks have been the envy and the nemesis of the 49ers for the past few years. Maybe this is another early elimination game, just like the Ravens game was on Sunday. The loser will be a lot further behind in the playoff hunt, and the 49ers probably feel they owe the Seahawks some payback. It should be an exciting night on Thursday in Santa Clara.

Sam McPherson is a freelance writer covering baseball, football, basketball, golf, hockey and fantasy sports for CBS, AXS and Examiner. He also is an Ironman triathlete and certified triathlon coach.