The Nick Foles-Carson Wentz debate always felt a bit silly, but Foles now has delivered the Philadelphia Eagles their two biggest victories of the 2018 season — a year after he led them to a Super Bowl title.

Although the Eagles led by two touchdowns with five minutes remaining against the Houston Texans, they watched as a heroic Deshaun Watson led a battered offense down the field twice for TD drives and a late 30-29 lead with just over two minutes remaining.

Foles had a little something left in what was a record-setting day for him. He led the Eagles down the field for a 10-play, 57-yard drive — even getting knocked out for a play — to give the Eagles a wild 32-30 victory that was clinched on Jake Elliott's 35-yard field goal at the buzzer.

Jadeveon Clowney's roughing-the-passer call, which forced Nate Sudfeld onto the field for one play, was a killer for Houston as it tacked on 15 yards following a 19-yard completion to Alshon Jeffery. That set up the game-winning kick.

And that also kept the Eagles' playoff hopes alive and had massive implications on the postseason landscape. The Vikings had a chance to clinch a playoff berth after winning, but the Eagles' victory delayed that for a week.

And the Texans losing means that the New England Patriots now are back in the No. 2 seed in the AFC, temporarily giving them a first-round bye, dropping Houston to the third slot. This now means the Texans are suddenly in a must-win situation entering Week 17 against the Jacksonville Jaguars, and they also have to hope for a New England loss next week to regain that first-round bye.

Foles finished with 471 pass yards, an Eagles record. He also threw four TDs and survived a fumble and an interception that helped keep the Texans alive for a bit. But following this and the road victory over the Rams, he's heating up at a crucial time for the Eagles, who — at least temporarily — have shut down Wentz with a back injury.

Watson had to rally the Texans with DeAndre Hopkins battling an ankle injury, Demaryius Thomas knocked out with a suspected Achilles injury and few healthy options at receiver. Facing a 29-13 deficit with five minutes remaining, Watson hit D'Onta Foreman and Vyncint Smith (his second NFL reception) on thrilling TD catches as it appeared Houston might steal one on the road and clinch the AFC South.

It didn't happen.

Foles completed 34-of-47 passes and had four different receivers with at least 76 yards. Zach Ertz, who broke Jason Witten's NFL record for catches by a tight end in a season (110) on Sunday, caught 12 passes for 110 yards and two scores.

Watson also ran for two touchdowns and passed for 339 yards with two scores. But the Eagles' late heroics — and the Texans' loose defense — prevented him from executing a brilliant comeback.