The 9th US Circuit Court of Appeals said it would not block a lower-court ruling that halted the order.
Mr Trump responded with an angry tweet saying national security was at risk and there would be a legal challenge.
But the 3-0 unanimous ruling said the government had not proved the terror threat justified reviving the ban.
The ruling means that people from Iran, Iraq, Libya, Somalia, Sudan, Syria and Yemen with visas can continue to enter the US.
And refugees from around the world, who were also subject to a temporary ban, are no longer blocked either.
The case is now likely to end up at the highest court, the US Supreme Court.