Mexico's supreme court says cases of military violations of citizens' civil rights should be tried in civilian courts, as recommended by an international tribunal.
But the justices stopped short of automatically taking all such cases out of military courts.
Mexico's army has been assigned to fighting drug cartels, but some soldiers have been accused of opening fire on civilians at checkpoints and conducting illegal searches and detentions.
Tuesday's ruling says Mexican courts must take into account a 2009 Inter-American Human Rights Court decision that says such cases don't belong in military courts.
Human rights activists note the ruling doesn't legally bind police, judges or prosecutors about how to handle rights cases.