A federal judge denied a request by Monroe County Sheriff Ruben Marté to temporarily block enforcement of a state law on immigration.
Marté filed a lawsuit against state attorney general Todd Rokita challenging a requirement for government entities to comply with immigration detainer requests.
The law goes into effect July 1.
The judge said the court lacked jurisdiction and the issue "is for the State of Indiana to work out."
Rokita celebrated the decision on social media, saying the law "will help ensure that criminal illegal aliens will not be released back onto our streets just because a sheriff refuses to cooperate with federal authorities."
An attorney for Monroe County did not immediately respond to a request for comment.