Passage of the measure with support from liberal Democrats — and no Republicans — could set up another difficult showdown between Speaker Nancy Pelosi of California and her left flank. Negotiations with the Senate will almost certainly result in a compromise measure that jettisons many, if not most, of the amendments secured by House liberals. That could set up a final vote that liberals will oppose, leaving Democratic leaders to appeal for Republican votes.

For now, though, the House bill bears the stamp of the resurgent left. The House passed a bipartisan amendment on Friday that would curb Mr. Trump’s ability to authorize a military strike on Iran unless he obtained Congress’s explicit approval. The 251-to-170 vote reflected general war weariness after almost two decades of conflict in the Middle East; 27 Republicans joined all but seven Democrats to approve it.

Last month, Mr. Trump led the United States to the brink of a retaliatory missile strike before abruptly reversing course minutes before launch. On Thursday, three Iranian boats briefly tried to block passage of a British tanker in the Strait of Hormuz, according to Britain’s Ministry of Defense.

Mr. Trump said last month he believes he does not need congressional approval to strike Iran. The vote on Friday amounted to a pointed bipartisan rebuttal — led by Representatives Ro Khanna, a liberal Democrat from California, and Matt Gaetz of Florida, one of Mr. Trump’s most strident Republican allies in Congress.

“If my war-hungry colleagues, some of whom have already suggested we invade Venezuela and North Korea and probably a few other countries before lunchtime tomorrow, if they’re so certain of their case against Iran,” Mr. Gaetz said, “let them bring their authorization to use military force against Iran to this very floor. Let them make the case to Congress and the American people.”