The verdict gives the green light for the plans to place 200 national guards at federal buildings where Washington claims that demonstrators are hindering the work of the migration authorities.
The decision applies until further notice, while the legal process surrounding the appeal of Trump's decision continues.
He has previously deployed military in, among other places, Los Angeles, Washington and Memphis.