Nick Foles was down and seemingly out as he lay on his back in the north end zone at Lincoln Financial Field. A few hundred yards away, outside the stadium, there’s the statue erected to the Eagles quarterback and coach Doug Pederson, forever ensconced calling “Philly Special.”

“I thought they were going to bury him next to the statue outside,” Eagles defensive end Chris Long joked. “They were going to have the statue, and then like a little tomb for him. But he got up, and that was cool.”

That he lived, yes, was good. But even cooler was that he returned and led the Eagles to a last-second, 32-30 victory over the Texans. In a career with triumphs and setbacks, twists and turns, and a touch of fairy dust, Sunday was just the latest chapter in the Legend of Foles.

» PLAYOFF PICTURE: Eagles-Washington moved to 4:25 p.m., final regular-season Sunday set up for big finish

Two weeks ago, the reigning Super Bowl MVP was on the bench, three games away from seemingly the end of his career with the Eagles. Foles may still have only one game left in Philadelphia, but not if he’s going to have anything to say about it.

Last week, it was knocking off the Rams. This week, it was overcoming a Houston comeback with a dramatic two-minute drive. Foles is entering the pantheon of greatest of NFL backups, and while that may be a dubious honor, he has relished another opportunity to lead the Eagles in Carson Wentz’s injured absence.

“It’s emotional,” Foles said, when asked the possibility of Sunday being his last home game at the Linc. “I love playing in Philly. I knew there was a chance this could be it. I don’t think about the future, but I am aware of that because this city means a lot to me, this team means a lot to me, wearing that jersey means a lot to me.”

There is, of course, the chance that the injury Foles suffered when Texans linebacker Jadeveon Clowney drove his helmet into his sternum will sideline him next week at the Redskins. Asked about the X-rays he took after the game, he would only say that his ribs felt “a little sore” and that he felt great.

But what if Wentz, who had a stress fracture in his back, were to be cleared to return? If Foles is healthy enough to play, it would be difficult for Pederson to go back to his starter, even though he has said that Wentz would get his job back as soon as he’s ready.

With Foles under center, the Eagles offense has put together its most productive back-to-back games all season. Houston was keen on stopping the run, but Foles took advantage through the air and set a franchise record for passing yards, completing 35 of 49 passes for 471 yards and four touchdowns.

Foles eclipsed the previous mark of 464 yards, set by Donovan McNabb in 2004, despite several loose throws, including an ugly interception to open the second half. But he kept firing, hitting Alshon Jeffery for 52 yards on his next throw, and a series later, when he dropped a rainbow into the lap of Nelson Agholor for an 83-yard touchdown.

Surveying the defensive coverage pre-snap, Foles audibled from one pass play to another.

“It was really all of us being on the same page,” Foles said, “recognizing the coverage, understanding how to run the route, and the line gave me time to throw it.”

But it will be the two third-down passes Foles completed on the game-winning drive that will be most remembered, especially if the Eagles go on to make the playoffs. After Houston took the lead, 30-29, the offense had the ball on its 11-yard line with two minutes left.

Two errant passes set up third-and-10, and the call was to go to Jeffery on a deep dig route.

“Coach [offensive coordinator Mike] Groh said [if] we’re going to lose, we going to throw it up and give me a chance,” Jeffery said. “So that’s what Nick did.”

Jeffery pulled in the pass 19 yards downfield, but Foles got clobbered by Clowney, who twisted inside.

“He got a good one on me,” Foles said.

As trainers huddled over Foles, the crowd started chanting his name, with many clapping their hands in unison over their heads. Wentz, meanwhile, called for center Jason Kelce to come to the sideline and practice snap to backup Nate Sudfeld.

Foles finally rose and jogged off to cheers. He needed only one play. Sudfeld took his mandatory one snap and fired a pass wide of receiver Jordan Matthews.

“I thought J-Matt got held a little bit, so I thought maybe defensive PI. And then everybody starts cheering,” Sudfeld said. “So I was like, ‘It was PI.’ And then I see Nick running on, and I was like, ‘Oh, OK.’”

Foles missed Agholor on a corner fade on his first play back, but on third down, Pederson dialed up a staple play that had Ertz run a “scissors corner route.” But the tight end got his feet tangled up with a defender on the break.

“There was a lot of stumbling going on so as I was releasing,” Foles said, “I tried to put a little more air on it because I was hoping he would keep his feet.”

Ertz did and his 20-yard grab advanced the Eagles to the Texans' 35 with 1:23 left. Foles would complete 12 of 13 passes for 149 yards and a touchdown on third down. Two plays later, Darren Sproles picked up 16 yards on a draw, was tackled for no gain on the next play, then Jake Elliott split the uprights from 35 yards out.

As Foles ran off the field, he blew kisses to fans who hung over the tunnel. The admiration is just and it extends to inside the locker room. If there’s any teammate that wouldn’t compliment Foles at the expense of Wentz, it’s Ertz, one of Wentz’s best friends on the team. He said as much, but there is no denying the Foles dynamic.

Nick Foles blows a kiss to the crowd while walking off the field after beating the Texans on Sunday.
TIM TAI / Staff Photographer
Nick Foles blows a kiss to the crowd while walking off the field after beating the Texans on Sunday.

“We love playing for him because he’s always exuding that positivity,” Ertz said. “He’s always going to give us a chance on those jump balls, those 50-50 balls, and I think he just ultimately trusts us to make plays.”

But Foles seems to inspire on both sides of the ball. Long, for instance, built a makeshift shrine to the quarterback in his locker stall last week.

“I want to be me,” Foles said. “I want to be genuine, and I think that’s a powerful thing.”

» GRADING THE EAGLES: Nick Foles, pass offense earn 'A'

Get insights on the Eagles delivered straight to your inbox with Early Birds, beat writer Zach Berman's newsletter for Eagles fans. Click here to sign up.

Our mission is to provide top-notch coverage for the best fans in sports. We can’t do it without your support. Join us: philly.com/birds