Trump is expected to issue a veto of the measure , his second as president, and Congress does not have the votes to override him. But the action was nonetheless a milestone for lawmakers, who have shown a renewed willingness to assert their war-making powers after letting them atrophy for decades under presidents from both parties.
"The president will have to face the reality that Congress is no longer going to ignore its constitutional obligations when it comes to foreign policy," said Democratic Rep. Eliot Engel of New York, chairman of the House Foreign Affairs Committee.
The conflict has been a bloody stalemate for years. Thousands have been killed in Saudi airstrikes on civilian infrastructure, and millions are on the brink of starvation. The war has devastated the economy of Yemen, the Arab world's poorest country. The vast majority of the population cannot afford food to eat.
Two lawmakers who have led the charge for the war powers resolution, Sens. Chris Murphy, D-Conn., and Bernie Sanders, I-Vt., have displayed photos of emaciated Yemeni children when they have given speeches on the Senate floor.
"This is a moral stain on this nation, every day that we continue to take part in this war," Murphy said after Thursday's vote.
Utah Sen. Mike Lee, a Republican who championed the measure, said it "is long past time that we end U.S. involvement in this unauthorized, unjustified, and immoral war that has caused immense human suffering."
While the U.S. has trained Saudi soldiers and sold the kingdom arms for decades, direct support to the Saudi coalition began in 2015, during the Obama administration, with intelligence sharing, logistical support and inflight refueling. The Pentagon ordered an end to inflight refueling last November.
Support for the coalition carried over into the Trump administration, which has made Saudi Arabia a central ally in efforts to disengage from the Middle East and take a hard line on Iran. On his first international trip as president, Trump visited Riyadh, where he emphasized business ties between the two countries. Home to key American military bases, Saudi Arabia also remains one of the top buyers of American arms and Trump has made it a priority to loosen weapons export controls.
As it has done in the past, his administration on Thursday defended the alliance with Saudi Arabia as a foreign policy imperative. Navy Cmdr. Rebecca Rebarich, a Pentagon spokeswoman, warned that curtailing U.S. military support could make the country's problems worse.
"New restrictions on the limited U.S. military support could still increase civilian casualties, jeopardize cooperation with our partners on counterterrorism, undercut UN-led peace negotiations at a critical point, and embolden Iran to increase its support to the Houthis which raises the risk for regional conflict," Rebarich said. "We need to continue to work with our partners to minimize civilian casualties and expand urgent humanitarian efforts throughout Yemen.
The White House statement threatening a veto said the bill raises "serious constitutional concerns." It also argued U.S. support for the Saudis coalition does not constitute engaging in "hostilities," meaning the War Powers Act doesn't apply.
Those arguments were echoed by House Republicans.
Rep. Michael McCaul of Texas, the top Republican on the House Foreign Affairs Committee, said the measure "does nothing to address the humanitarian crisis in Yemen" and argued the lawmakers were abusing the authority under the War Powers Resolution, which was enacted in 1973.
"This radical interpretation has implications far beyond Saudi Arabia," McCaul said. He warned that the measure could "disrupt U.S. security cooperation agreements with more than 100 countries."
Debate over U.S. support to the military campaign flared late last year after the killing of U.S.-based journalist Jamal Khashoggi by agents of the kingdom. Lawmakers from both parties said Trump had not condemned Saudi Arabia strongly enough, citing the president's apparent dismissal of assessments from U.S. intelligence agencies that the Saudi Crown Prince Mohammed bin Salman ordered the killing.
A resolution to withdraw U.S. support from the war passed the Senate in December, and was revived this year after Democrats took the House majority.
Final passage Thursday came despite a procedural gambit from House Republicans related to support for Israel, an issue that has been a point of tension for Democrats in recent months. GOP leaders proposed adding language condemning the international boycott movement against Israel and efforts to delegitimize the country.
Democrats called the amendment a ploy to kill the Yemen resolution and rallied against it.
"This is about politics, this is about trying to drive a wedge into this caucus where it does not belong," said Rep. Ted Deutch, D-Fla., to applause from Democrats.
As the resolution headed to the White House, supporters in both parties made a final plea for Trump to sign it. A letter signed by Lee, Sanders, Sen. Rand Paul, R-Ky., and members of the House cited Trump's desire to avoid "costly and never-ending conflicts across the globe."
By signing the resolution, the lawmakers wrote, the president could "set a new precedent" and take on "entrenched opposition to foreign-policy restraint."
Asked about the resolution late Thursday, Trump was noncommittal.
"I'll take a look at it," he told reporters at the White House.
Associated Press writers Lolita Baldor and Deb Riechmann contributed from Washington
For more coverage of the war in Yemen from the AP, go to: https://apnews.com/YemenDirtyWar