The decision -- the latest in a series of stinging judicial defeats for the Republican billionaire, who took office in January -- means the case is likely to end up in the Supreme Court.
At issue was the intent behind the measure -- whether or not it deliberately singled out Muslims by targeting nationals from Iran, Libya, Somalia, Sudan, Syria and Yemen. Religious discrimination is forbidden by the US Constitution.
The Fourth Circuit Court of Appeals said it "remained unconvinced" that the part of the measure naming the specific countries had "more to do with national security than it does with effectuating the president's promised Muslim ban."
The court -- based in Richmond, Virginia -- further said it could not find that the government's security concerns outweighed the plaintiffs' concerns about discrimination.
"Congress granted the president broad power to deny entry to aliens, but that power is not absolute," Chief Judge Roger Gregory said in the 10-3 ruling.
"It cannot go unchecked when, as here, the president wields it through an executive edict that stands to cause irreparable harm to individuals across this nation."
Gregory said the order "speaks with vague words of national security, but in context drips with religious intolerance, animus, and discrimination."
Given the high-profile nature of the case, the full appeals court in Richmond heard the arguments -- bypassing the usual initial three-judge panel -- for the first time in a quarter-century.
Thirteen of the court's 15 active judges took part. Two recused themselves over potential conflicts of interest.
Trump issued his initial travel ban by executive order in January, but that measure -- which banned entry to nationals from seven countries for 90 days and suspended the nation's refugee program for 120 days -- was quickly halted by the courts.
The measure nevertheless earned widespread opposition, including from rights activists and states led by Democrats.
A district court judge in Maryland issued a nationwide block on the ban's core provision concerning travel from the short list of countries, sending the issue to the Fourth Circuit.
In a May 8 hearing, acting solicitor general Jeffrey Wall, representing the government, insisted that Trump "never intended for that to discriminate on the basis of any particular religion."
"He made clear he was not talking about Muslims all over the world," said Wall. "That's why it's not a Muslim ban."
But Omar Jadwat, a lawyer for the American Civil Liberties Union -- which represented the associations who were the plaintiffs in the case -- argued that Trump the candidate made clear he wanted to ban all Muslims for a time while studying enhanced immigration vetting.
"We won," the ACLU and Jadwat tweeted Thursday.
"The Constitution's prohibition on actions disfavoring or condemning any religion is a fundamental protection for all of us, and we can all be glad that the court today rejected the government's request to set that principle aside," Jadwat said.
A federal court in Hawaii has issued a broader injunction that halted both the travel ban and the suspension of the US refugee admissions program.
The White House is fighting that ruling in the Ninth US Circuit Court of Appeals, based in San Francisco, which heard the case on May 15. A decision is pending.
(This story has not been edited by NDTV staff and is auto-generated from a syndicated feed.)