New York City Council Speaker Corey Johnson criticized federal agents and city police Thursday for what he called an overly aggressive response to a protest sparked by the detainment of an immigrant-rights leader.

Mr. Johnson was one of scores to rush to Federal Plaza in lower Manhattan after Ravi Ragbir, the executive director of the New Sanctuary Coalition of New York City, was detained for possible deportation during a scheduled check-in at the U.S. Immigration and Customs Enforcement field office. Mr. Ragbir fainted when...