Miami dropped defending Super Bowl champions New England into the wild-card playoff round when Ryan Fitzpatrick tossed a five-yard touchdown pass to tight end Mike Gesicki with 24 seconds remaining for a stunning 27-24 victory Sunday.

New England (12-4) will have to play in the opening weekend of the postseason for the first time since 2009. The Patriots never have won the Super Bowl while playing in the wild-card round and only once reached the NFL title game having entered the playoffs at that stage. Raymond Berry’s 1985 team went on to lose to the most lopsided Super Bowl in history to the Chicago Bears and their famous defense on that occasion.

The Patriots won their first eight games, the split the next eight, including the rarity of two losses at home.

It is the second straight season the Dolphins have denied the Patriots an unbeaten division record. They scored on a wild series of laterals on the final play in their second meeting last season, in Miami.

After trailing throughout the game, Tom Brady threw a 13-yard touchdown pass to James White to put New England in front 24-20 with 3:53 left. But Fitzpatrick, who finished 28 of 41 for 320 yards and a touchdown, was unflappable, leading Miami on a 13-play, 75-yard drive that included him recovering a fumbled snap, and completing a 24-yard pass to DeVante Parker for Miami (5-11).

LA Chargers 21-31 Kansas City Chiefs

Mecole Hardman returned a kickoff 104 yards for a touchdown, Damien Williams took a handoff 84 yards for another score, and the Chiefs leapfrogged New England for the No 2 seed in the AFC and a first-round playoff bye.

The Chiefs (12-4) long ago clinched their fourth straight AFC West title, but they needed a win and an unlikely Dolphins victory over the Patriots to get a week off. And just as Williams punched into the end zone in the closing minutes for his second touchdown of the game, the Dolphins were scoring the go-ahead TD with 24 seconds left for their upset in Foxborough.

Now, the Patriots will have to play next weekend while the Chiefs set their sights on the divisional round of the playoffs.

The Chargers (5-11) made it stressful for Kansas City in the fourth quarter, though, driving for a touchdown that got them within 24-21 with 5:23 to go. But the Chiefs answered with an eight-play, 77-yard scoring drive that allowed them to wrap up their sixth straight win overall and 11th victory in 12 meetings with their longtime division rival.

Philadelphia Eagles 34-17 New York Giants

Carson Wentz and the Philadelphia Eagles are heading to the playoffs thanks to a group of players off the practice squad.

Boston Scott ran for three touchdowns in the second half and the injury-ravaged Eagles beat the Giants to win the NFC East title.

Philadelphia host Seattle (11-5) in a wild-card game next weekend.

Already missing three starting wide receivers for the fourth straight game, the Eagles also began the game without Pro Bowl tight end Zach Ertz and right tackle Lane Johnson.

Then they lost running back Miles Sanders and three-time Pro Bowl right guard Brandon Brooks in the first half.

But Wentz guided the Eagles (9-7) to their fourth straight win and second division title in three seasons. Wentz threw for 289 yards, including a 24-yard TD pass to Josh Perkins, who was promoted from the practice squad on 30 November.

Scott had TD runs of seven, two and two yards. He came off the practice squad earlier in the season. Scott had 54 yards rushing and 84 receiving.

While the Eagles head to the playoffs for the third straight year seeking their second Super Bowl title, the Giants (4-12) face more uncertainty. Coach Pat Shurmur’s job status is a question after going 9-23 in two seasons.

San Francisco 49ers 26-21 Seattle Seahawks

The 49ers won the NFC West and the No 1 seed when Jacob Hollister was stopped by rookie linebacker Dre Greenlaw on fourth-and-goal just inches short of the goal line. San Francisco claimed its first division crown since 2012 and wrapped up home-field advantage throughout the NFC playoffs by silencing a crowd that showed up looking for a division title and to celebrate the return of Marshawn Lynch.

But it took a replay review for San Francisco to finally have its title.

Seattle took possession at its 27 with 2:27 left down by five. Russell Wilson drove the Seahawks to the San Francisco 12 and on fourth-and-10, Wilson hit John Ursua for 11 yards to the 1. Wilson spiked the ball, but Seattle (11-5) was called for delay of game on second down with confusion about whether Lynch should enter the game. Backed up to the 6, Wilson was incomplete on two straight passes.

On fourth-and-goal Hollister caught the underneath pass but was knocked down by Greenlaw. Replay confirmed Hollister hit the ground before the ball reached the goal line and San Francisco (13-3) had won.

Seattle visit Philadelphia next Sunday. San Francisco have a bye.

Tennessee Titans 35-14 Houston Texans

Derrick Henry and the Titans ran their way into the playoffs, beating a Houston team that rested several starters, and setting up an intriguing first-round matchup with New England.

Henry rushed for a season-high 211 yards and three touchdowns. The Texans beat the Titans two weeks ago to take control of the AFC South and locked up the division last week, allowing Houston (10-6) to sit quarterback Deshaun Watson and other key players.

Tennessee (9-7) got its first win at Houston since 1 January 2012. The Titans, who will visit the Patriots next weekend, are in the postseason for the second time in three seasons and the first under coach Mike Vrabel, who played for New England for eight seasons.

Ryan Tannehill threw for 198 yards and two touchdowns for Tennessee and will make his playoff debut in his eighth NFL season. Rookie receiver AJ Brown had 124 yards receiving and a touchdown.

Watson was active on Sunday, but coach Bill O’Brien started AJ McCarron instead. Watson was listed as questionable with a back injury this week but said he was OK. Receiver DeAndre Hopkins was also active, but did not play and several starters, including receiver Kenny Stills, left tackle Laremy Tunsil and nose tackle D.J. Reader, were inactive.

McCarron threw for 225 yards with an interception and ran for a touchdown.

Washington 16-47 Dallas Cowboys

Dak Prescott threw four touchdown passes in a win rendered meaningless when the Cowboys were eliminated from the playoffs by Philadelphia’s victory.

The Cowboys (8-8) lost control of their playoff future with a 17-9 loss at the Eagles last week. Last season’s NFC East champions will now wait to see how much longer Jason Garrett will be coach after underachieving in the final year of his contract.

Dallas could have made the playoffs without a winning record for the third time in franchise history. Instead, the Eagles won the division for the second time in three years.

Case Keenum had a TD toss as the Redskins (3-13) secured the No 2 pick in the draft in what could be their final game under interim coach Bill Callahan. The former Dallas assistant replaced Jay Gruden, fired in October with Washington at 0-5.

Prescott, playing with a sprained right shoulder for the second straight game and looking much better than he did in the loss at Philadelphia, was 23 of 33 for 303 yards. He fell 1 yard short of Tony Romo’s club record of 4,903 yards passing for a season.

In receiver Michael Gallup’s first career game with multiple touchdowns, the second-year player had five catches for 98 yards.

Green Bay Packers 23-20 Detroit Lions

Mason Crosby kicked a 33-yard field goal as time expired, lifting the Packers to a first-round bye.

The Packers (13-3) fell behind by two touchdowns in the second quarter. They didn’t lead until Crosby made his second winning kick against Detroit this season.

The Lions (3-12-1) closed with nine straight losses for their longest losing streak in a season since going 0-16 in 2008.

Green Bay won despite Aaron Rodgers struggling to make accurate throws for much of the afternoon. Rodgers was 27 of 55 for 323 yards with two touchdowns and an interception. He made a short pass under pressure to Aaron Jones, who turned the clutch throw into a 31-yard reception to set up Crosby’s kick.

Jones ran for 100 yards on 25 carries and had 43 yards receiving. Davante Adams had seven receptions for 93 yards and a score.

There was a long moment of silence before the game for receiver Marvin Jones’ 6-month old son, who recently died. Jones, who was on the sideline with his family during the national anthem, went on injured reserve earlier this month.

New Orleans Saints 42-10 Carolina Panthers

The Saints took care of business against the reeling Panthers and finished off a 13-3 regular season but still might not get a week of rest in the playoffs.

Drew Brees threw for 253 yards and three touchdowns, Alvin Kamara ran for two scores and the Saints handed the Panthers their eighth straight loss. But the runaway NFC South champions’ chances at home-field advantage throughout the NFC playoffs ended when Green Bay beat Detroit on a last-second field goal. New Orleans needs Seattle to beat San Francisco on Sunday night to earn a first-round bye. If the 49ers win, the Saints will be the No 3 seed and host the Minnesota Vikings in the wild-card round next weekend.

The only thing that went right for the Panthers (5-11) was Christian McCaffrey joining Roger Craig and Marshall Faulk as the third player in NFL history to record 1,000 yards rushing and 1,000 yards receiving in the same season. McCaffrey needed 67 yards receiving coming in and got there with a 17-yard reception late in the third quarter, earning some bear hugs from teammates on the sideline and a standing ovation from the scattered fans remaining in the seats.

Pittsburgh Steelers 10-28 Baltimore Ravens

Slogging through the rain without several notable stars and with very little at stake, the Ravens relied on a strong defensive performance to finish the regular season riding a 12-game winning streak.

Baltimore’s first touchdown followed a fumble by Steelers rookie quarterback Devlin Hodges, who failed to generate any offense in a game that meant far more to Pittsburgh (8-8) than to the Ravens (14-2).

Baltimore also scored on special teams when Steelers punter Jordan Berry couldn’t handle the wet football and Jordan Richards recovered the fumble for a touchdown. Fifteen seconds later, the Ravens tacked on a safety when Hodges was called for intentional grounding in his end zone.

Baltimore already clinched the top seed in the AFC playoffs, so coach John Harbaugh placed seven starters on the inactive list — including quarterback Lamar Jackson, injured running back Mark Ingram (calf), guard Marshal Yanda and safety Earl Thomas.

All seven players, six of whom were voted to the Pro Bowl, should return to action on the weekend of Jan. 11-12, when Baltimore opens postseason play following a first-round bye.

Pittsburgh entered the game needing help to fulfill its quest to become only the seventh team since 1970 to reach the playoffs after an 0-3 start. The easiest route for Pittsburgh to qualify was a victory over Baltimore combined with a Tennessee loss to Houston. The Titans, however, won 35-14 to earn the final AFC wild-card slot. The Steelers could have gotten in with a loss, but all those equations included Tennessee losing.

Oakland Raiders 15-16 Denver Broncos

Shelby Harris knocked down Derek Carr’s two-point pass to Hunter Renfrow with seven seconds left and the Broncos put an end to Oakland’s run as an NFL city.

The Raiders (7-9) nearly made the Broncos (7-9) pay dearly for Garett Bolles’ latest penalty, a personal foul that pushed Brandon McManus way back for a 57-yard field-goal attempt, which sailed wide left, giving Oakland the ball at its 45-yard line with 1:41 remaining.

Carr hit Renfrow for the touchdown from the 3, the first time the Raiders reached the end zone in five red-zone trips. Coach Jon Gruden went for the 2-point conversion instead of the tie.

The Raiders had an outside shot of making the playoffs for just the second time since 2002, but they needed several things to go right, starting with a win.

Rookie Drew Lock won for the fourth time in his five starts and Phillip Lindsay topped 1,000 yards rushing for the second straight season for Denver, which went 7-5 after a winless September under first-year head coach Vic Fangio.

The Raiders lost five of their last six games in missing the playoffs for the second straight season under Gruden.

Indianapolis Colts 20-38 Jacksonville Jaguars

Gardner Minshew turned in his best performance in two months, throwing for 295 yards and three touchdowns. The rookie closed out Jacksonville’s disappointing season by strengthening his case to be the team’s starting quarterback next season. Coach Doug Marrone might be around, too.

Marrone’s status has been unclear since team owner Shad Khan fired top executive Tom Coughlin last week. Khan will meet with Marrone, general manager Dave Caldwell and others in the coming days before deciding anyone’s fate. Marrone and Caldwell have two years remaining on their contracts.

Minshew and the Jaguars (6-10) certainly made Marrone look good in the regular-season finale for both teams. Minshew connected with Keelan Cole, Ryquell Armstead and Dede Westbrook for touchdowns, showing poise in the pocket and enough mobility to turn nothing into something.

The Colts (7-9) had a chance to finish .500 or better for the seventh time in the past eight years. But they did little on offense in the second half and finished below .500 for the second time in three years.

Arizona Cardinals 24-31 LA Rams

Tyler Higbee and Robert Woods caught touchdown passes from Jared Goff in the fourth quarter, and the Rams bade farewell to the Los Angeles Coliseum and secured their third straight winning season.

Goff passed for 319 yards and hit Cooper Kupp for 99 yards and an early TD, while the Los Angeles defense made four takeaways in the final NFL game at the 96-year-old Coliseum. The Rams (9-7) are moving into palatial SoFi Stadium in Inglewood next season.

The 2018 NFC champions were eliminated from playoff contention last week, but they improved to 6-0 against Arizona during coach Sean McVay’s tenure while securing this franchise’s first string of three straight winning records since 1999-2001.

Kyler Murray wrapped up his stellar rookie season with 327 yards passing for the Cardinals (5-10-1), who finished coach Kliff Kingsbury’s debut year with their fourth consecutive losing record.

Larry Fitzgerald had four catches for 45 yards in perhaps the final game of his stellar 16-year career. The 36-year-old receiver, second in NFL history in catches and yards behind Jerry Rice, hasn’t decided whether he will accept the Cardinals’ pleas to return next year.

Chandler Jones was held without a sack of Goff, which means the star Arizona defensive lineman lost the NFL sacks title to Tampa Bay’s Shaquil Barrett, who had three sacks Sunday to finish with 19½ this season, ahead of Jones’ 19.

Chicago Bears 21-19 Minnesota Vikings

Eddy Piñeiro’s fourth field goal of the game for Chicago came from 22 yards with 10 seconds left with the Vikings resting their regulars for the playoffs.

Piñeiro, the latest attempt by the Bears (8-8) to solve their persistent kicking trouble, finished the season with 11 straight made field goals. Mitch Trubisky highlighted another unremarkable performance by hitting Riley Ridley for 34 yards on fourth-and-9 with 2:36 left from midfield to set up the winning kick.

David Montgomery had 23 carries for 113 yards and a touchdown to cap a strong rookie season and help the Bears beat the Vikings (10-6) for the fourth consecutive time. Chicago dodged what would have been a fifth losing record in six years, after winning the NFC North in 2018 in coach Matt Nagy’s debut.

Minnesota missed a third 11-win season in six years under coach Mike Zimmer, but he was far more concerned about taking a healthy team to the playoffs. The only drama in the building was the way the Green Bay-Detroit game was unfolding, with a significant impact on where the Vikings will play their first-round game.

Ifeadi Odenigbo strip-sacked Trubisky in the fourth quarter to pick up the ball and set up Dan Bailey’s fourth field goal for a brief lead for the Vikings, but a replay review negated what would have been Odenigbo’s second fumble return for a touchdown in three games after it was ruled that his knee was down after the recovery.

Cleveland Browns 23-33 Cincinnati Bengals

Andy Dalton threw for a touchdown and ran for another in his farewell as a franchise quarterback — a Joe Burrow banner in the upper deck reminded him what comes next — and the Bengals ended one of their most miserable seasons with a victory.

Ohio’s two professional football teams wrapped up another fruitless year together and set course for an offseason of potentially big changes.

The Bengals (2-14) matched the worst record in their 52-year history. They’ll pick first in the draft for the first time since 2003, when they also were coming off a 2-14 finish and chose franchise quarterback Carson Palmer.

Cleveland (6-10) was a chic Super Bowl pick with Baker Mayfield coming off a sensational rookie season and Odell Beckham Jr. adding star quality to the offense. Instead, the Browns significantly regressed under first-year coach Freddie Kitchens, who was fired later in the day.

Dalton threw a 15-yard touchdown pass and scrambled 5 yards for another score in the Bengals’ highest-scoring first half of the season for a 20-16 lead. He finished 16 of 28 for 190 yards. Joe Mixon ran for a career-high 162 yards and a pair of touchdowns, topping 1,000 yards for the second straight year.

Atlanta Falcons 28-22 Tampa Bay Buccaneers (OT)

Deion Jones intercepted Jameis Winston on the first play of overtime and returned the ball 27 yards for a touchdown.

Winston became the first Tampa Bay quarterback to pass for 5,000 yards in a season, but another non-playoff year ended on a sour note. The Falcons (7-9) tied the game with a field goal on the last play of regulation and won for the sixth time in eight games when Jones became the seventh opposing player to score on a pick-wis off Winston this season.

Matt Ryan completed 30 of 51 passes for 313 yards and one touchdown for the Falcons, who saved coach Dan Quinn’s job by rebounding from a 1-7 start to go 6-2 over the second half of the season. Atlanta will finish second in the NFC South despite posting a losing record for the second year in a row.

Winston threw for 201 yards, two touchdowns and two interceptions, hiking his NFL-leading total to 30. Ronald Jones II had the first 100-yard rushing performance and Breshad Perriman topped 100-yards receiving for the third straight week for the Bucs (7-9), who miss the playoffs for the 12th consecutive year.

Ryan only got the Falcons into the end zone once, throwing a 35-yard TD pass to a wide- open Ty Sambrailo, a 6-foot-5, 311-pound backup offensive tackle.

New York Jets 13-6 Buffalo Bills

Sam Darnold hit Jamison Crowder for a one-yard touchdown pass in the fourth quarter, and New York avoided finishing its fourth consecutive season with double-digit losses in a win over Buffalo’s backups.

The Jets missed the playoffs for a ninth consecutive season, but finished at 7-9 under first-year coach Adam Gase for their best record since going 10-6 in 2015.

The playoff-bound Bills had very little to play for while resting most of their starters, including quarterback Josh Allen after the first quarter. Buffalo dropped to 10-6 — still its best finish since going 11-5 in 1999 — and entered the game already locked in as the AFC’s fifth seed.

The Bills will travel to play AFC South champion Houston Texans in the wild-card playoff round next weekend. The Texans were assured of the No. 4 seed after Kansas City defeated the Los Angeles Chargers.

This article was amended after publication to reflect the fact that the New England Patriots reached the Super Bowl having played in the wild-card round, doing so in 1985.