Michael Grimm, who is trying to win back his old House seat after serving time in federal prison, secured a notable new supporter on Wednesday: Stephen K. Bannon, President Trump’s former chief strategist, who has sought to bolster the candidacies of populist outsiders since leaving the White House.

The two met at Mr. Bannon’s Capitol Hill townhouse on Wednesday afternoon, three days after Mr. Grimm announced he was challenging Representative Dan Donovan of Staten Island for the Republican nomination in New York City’s last G.O.P.-held congressional seat.

“We’re joining the Bannon portfolio of Republican challengers to anti-Trump Republican congressmen,” said Michael Caputo, a Grimm adviser who also served as an adviser to Mr. Trump during the 2016 presidential campaign.