The justices ruled that the state’s law, which prohibited some medical treatments for transgender youths, did not violate equal protection principles.

This decision could set a tone for other challenges to laws barring transgender people from participating in sports, using bathrooms and accessing health care.

The justices rejected the argument that restrictions in Tennessee discriminated against young trans people.