District Magistrate Vijay Karan Anand ordered to leave the boundaries of the district under the Goonda Act.
Violation of the order would attract punishment in accordance with the law.
An official said that there were apprehensions that they could create hindrance in the election process.
The assembly elections in Uttar Pradesh will be held from February 11 to March 8 in seven phases.
Disclaimer: No Business Standard Journalist was involved in creation of this content