The Buffalo Billsit will be returning to the playoffs for the seventh consecutive season.

Following their 23-20 win over the Cleveland Browns, Buffalo needed the Houston Texans or Indianapolis Colts to lose in Week 16 to secure a playoff spot. The Texans won a nailbiter over the Las Vegas Raiders, leaving Bills fans to root for the San Francisco 49ers on Monday Night Football.

The 49ers did their part for Buffalo, delivering a 48-27 win over the Colts. Indianapolis’ loss clinched berths for Buffalo, the Los Angeles Chargers and Jacksonville Jaguars. The Colts are not officially eliminated from playoff contention at this point, but they will need plenty of help to sneak in.

Buffalo punched their ticket to the postseason, but it still has plenty to play for with two games remaining. The Bills can win the AFC East if they win out and the New England Patriots drop one of their final two matchups on the road against the New York Jets or at home against the Miami Dolphins. Both scenarios, however, seem unlikely as the Jets and Dolphins are playing for draft status more than wins at this point in the season with backup quarterbacks. New York has said that Brady Cook will start the final two games of the season for the Jets and Quinn Ewers is expected to start for Miami.

If Buffalo fails to win the division, they still have Wild Card seeding to play for over the final two weeks of the season.

As of now, Buffalo holds the No. 6 seed in the playoffs. That would currently give the Bills a matchup against a Jacksonville Jaguars team that just defeated the AFC’s No. 1 seed, the Denver Broncos, handily.