ORCHARD PARK, N.Y. — In that instant, Brandon Marshall thought he was done.

Just like that, he figured his season and potentially his career were finished. All because of an illegal tackle.

“I thought it was over,” he said Thursday night after the Jets defeated the Buffalo Bills, 37-31, at New Era Field.

Marshall’s left leg bent awkwardly after he was taken down by Stephen Gilmore’s horse-collar tackle after making a second-quarter catch. Writhing in pain, he grabbed his left knee and had to be helped to his feet. After being checked out on the examination table behind the Jets’ bench, he limped to the locker room, followed by general manager Mike Maccagnan.

But to the surprise of everyone — including his quarterback — Marshall jogged out of the tunnel a short time later and returned to action.

What at first appeared to be a significant knee injury was described by Jets coach Todd Bowles as a possible “slight sprain.” Marshall also seemed optimistic about playing next week against the Chiefs.

advertisement | advertise on newsday

“Brandon is one of the tougher guys you’ll ever see,” Ryan Fitzpatrick said of his star playmaker, who caught six passes for 101 yards. “ . . . I didn’t know if it was a T.O. injury with a broken fibula, a knee.

“ . . . I didn’t think it was good. To see him on the ground in pain, I knew something was wrong. But then when he stepped back into the huddle later on, it was a such a surprise, but it was relief as well . . . I thought he was down for the count for sure.”

So did Marshall.

“I thought I was going to be fishing in my backyard in Florida,” he joked, adding that his left leg went numb briefly. “ . . . I’m just fortunate and blessed that I was able to finish the game and it’s not a season-ending thing.”

Teammate Eric Decker said he was “nervous” once he saw Marshall “whip back” and grab his knee. “He’s a tough dude,” he said, smiling. “To come back and make plays like he did just shows the athlete and just the beast that he is.”