Immigration and Customs Enforcement agents looking to make arrests inside courthouses in New York can't do so without judicial warrants or orders.

That's according to a directive from the New York State Office of Court Administration that took effect Wednesday.

Immigrant advocates say courthouses in New York and elsewhere have increasingly become places where immigrants have been taken into federal immigration custody. ICE agents could enter court buildings with just an administrative ICE warrant.

Any law enforcement with the proper warrant will now have to identify themselves to Unified Court System personnel in the courthouse and state their reason for being there before they can make an arrest.

Legal Aid Society celebrated the announcement as a "big victory" for immigrants.

A report by the Immigrant Defense Project says there were 178 arrests in New York state courthouses last year, compared to 11 in 2016.

Advocates say immigrants have become afraid to visit courts as a result.

Chief Administrative Judge Lawrence Marks says the system needs people to be willing to come to court "for judges to be able to do their jobs."

ICE did not immediately comment.

------

Information from the Associated Press was used in this story.