Four weeks ago, 2016 looked like a lost season for both Buffalo and Washington. Both teams began the season with two losses, and teams that start out 0-2 have a very rough time of things.

But it wasn’t just the 0-2 record on the field; the teams looked ugly off the field, too. After the team’s second loss, Buffalo fired offensive coordinator Greg Roman, a move widely viewed as an attempt by head coach Rex Ryan to make Roman into a scapegoat for the team’s problems. In Washington, rumors swirled that the locker room was holding quarterback Kirk Cousins responsible — and that caused head coach Jay Gruden to issue the dreaded vote of confidence for his starter.

Now? Both teams are riding four-game winning streaks and look like playoff contenders. Before this year, only 18 teams in NFL history had started a season 0-2 and then won four straight games. Over the past 20 years, this season’s Buffalo and Washington squads are only the fourth and fifth teams to do so. So how did they do it? Although the NFL continues to shift toward the passing game, both teams have zagged and rebounded thanks to their ground game.

During the four-game winning streak, LeSean McCoy of Buffalo has 73 carries for 470 yards (a 6.44 average) and five rushing touchdowns, while Bills quarterback Tyrod Taylor has 24 carries for 204 yards and a touchdown (excluding kneels). And although Ezekiel Elliott and the Cowboys’ running game have deservedly received a lot of attention, the Bills lead the NFL in rushing yards (847), yards per carry (6.27), rushing touchdowns (8), and rushing first downs (42) since the beginning of Week 3. That’s the most by any team in a four-game stretch since the final four games of the 2012 Seahawks’ regular season.

The unsung heroes for the Bills are the offensive line and fullback Jerome Felton. During this four-game winning streak, Buffalo has gained an incredible 648 rushing yards before contact, which translates into 4.80 yards before contact per run; for reference, the Texans (3.30), Titans (3.29) and Cowboys (3.20) are the next closest teams. Under new offensive coordinator Anthony Lynn, a former running back and a running backs coach for over a decade, the offense now boasts the league’s best running game, deploying creative, unbalanced looks to get its backs into space.

Against San Francisco on Sunday, Buffalo became the first team to rush for 300 yards in a game since 2014, piling up 312 yards on 44 attempts. And up next for the Bills? A Miami defense that ranks 31st against the run.

For Washington, the season began with a pair of pass-happy games: Washington had 93 quarterback dropbacks through two weeks against just 26 carries given to running backs; that ratio of 3.6:1 was the most pass-happy in the league. Some, but not all, was due to the team trailing, and just once over that span did Washington call back-to-back running plays!

Since then, there has been a big change in philosophy, one that has been helped by Washington’s taking more snaps while playing with the lead. In Weeks 3 through 6, the team had 143 quarterback dropbacks and 102 running back carries; that 1.4:1 ratio was the fifth-most run-heavy over that time. The reason this strategy has worked? Washington running backs are averaging 5.22 yards per carry during this streak and have picked up a first down on 27.5 percent of carries; both marks rank in the top four over this time period.

As it has been in Buffalo, the offensive line has been a big part of Washington’s success. According to Pro Football Focus, offensive tackle Trent Williams is having another magnificent season; he and Morgan Moses both rank among the 15 best run-blocking tackles; and guard Brandon Scherff is the 12th-rated run-blocker at his position. The team also benefits from having athletic tight ends in Jordan Reed, Vernon Davis and Niles Paul. Collectively, the three combined to average 1.52 snaps per play between them through Week 5 ; in other words, Washington runs a lot of two tight-end sets but can do so without giving away that the ultimate play design is a run.

For Buffalo and Washington, the 2016 season has renewed life. And both teams have gotten here by embracing the running game.