Chief Justice Burger
delivered the opinion of the Court.
We granted certiorari to review a judgment of a state court divesting a natural mother of the custody of her infant child because of her remarriage to a person of a different race.
I
When petitioner Linda Sidoti Palmore and respondent Anthony J. Sidoti, both Caucasians, were divorced in May 1980 in Florida, the mother was awarded custody of their 3-year-old daughter.
In September 1981 the father sought custody of the child by filing a petition to modify the prior judgment because of changed conditions. The change was that the child’s mother was then cohabiting with a Negro, Clarence Palmore, Jr., whom she married two months later. Additionally, the father made several allegations of instances in which the mother had not properly cared for the child.
After hearing testimony from both parties and considering a court counselor’s investigative report, the court noted that the father had made allegations about the child’s care, but the court made no findings with respect to these allegations. On the contrary, the court made a finding that “there is no issue as to either party’s devotion to the child, adequacy of housing facilities, or respectability of the new spouse of either parent.” App. to Pet. for Cert. 24.
The court then addressed the recommendations of the court counselor, who had made an earlier report “in [another] case coming out of this circuit also involving the social consequences of an interracial marriage. Niles v. Niles, 299 So. 2d 162.” Id., at 25. From this vague reference to that earlier case, the court turned to the present case and noted the counselor’s recommendation for a change in custody because “[t]he wife [petitioner] has chosen for herself and for her child, a life-style unacceptable to the father and to society. . . . The child ... is, or at school age will be, subject to environmental pressures not of choice.” Record 84 (emphasis added).
The court then concluded that the best interests of the child would be served by awarding custody to the father. The court’s rationale is contained in the following:
“The father’s evident resentment of the mother’s choice of a black partner is not sufficient to wrest custody from the mother. It is of some significance, however, that the mother did see fit to bring a man into her home and carry on a sexual relationship with him without being married to him. Such action tended to place gratification of her own desires ahead of her concern for the child’s future welfare. This Court feels that despite the strides that have been made in bettering relations between the races in this country, it is inevitable that Melanie will, if allowed to remain in her present situation and attains school age and thus more vulnerable to peer pressures, suffer from the social stigmatization that is sure to come.” App. to Pet. for Cert. 26-27 (emphasis added).
The Second District Court of Appeal affirmed without opinion, 426 So. 2d 34 (1982), thus denying the Florida Supreme Court jurisdiction to review the case. See Fla. Const., Art. V, §3(b)(3); Jenkins v. State, 385 So. 2d 1356 (Fla. 1980). We granted certiorari, 464 U. S. 913 (1983), and we reverse.
II
The judgment of a state court determining or reviewing a child custody decision is not ordinarily a likely candidate for review by this Court. However, the court’s opinion, after stating that the “father’s evident resentment of the mother’s choice of a black partner is not sufficient” to deprive her of custody, then turns to what it regarded as the damaging impact on the child from remaining in a racially mixed household. App. to Pet. for Cert. 26. This raises important federal concerns arising from the Constitution’s commitment to eradicating discrimination based on race.
The Florida court did not focus directly on the parental qualifications of the natural mother or her present husband, or indeed on the father’s qualifications to have custody of the child. The court found that “there is no issue as to either party’s devotion to the child, adequacy of housing facilities, or respectability of the new spouse of either parent.” Id., at 24. This, taken with the absence of any negative finding as to the quality of the care provided by the mother, constitutes a rejection of any claim of petitioner’s unfitness to continue the custody of her child.
The court correctly stated that the child’s welfare was the controlling factor. But that court was entirely candid and made no effort to place its holding on any ground other than race. Taking the court’s findings and rationale at face value, it is clear that the outcome would have been different had petitioner married a Caucasian male of similar respectability.
A core purpose of the Fourteenth Amendment was to do away with all governmentally imposed discrimination based on race. See Strauder v. West Virginia, 100 U. S. 303, 307-308, 310 (1880). Classifying persons according to their race is more likely to reflect racial prejudice than legitimate public concerns; the race, not the person, dictates the category. See Personnel Administrator of Mass. v. Feeney, 442 U. S. 256, 272 (1979). Such classifications are subject to the most exacting scrutiny; to pass constitutional muster, they must be justified by a compelling governmental interest and must be “necessary ... to the accomplishment” of their legitimate purpose, McLaughlin v. Florida, 379 U. S. 184, 196 (1964). See Loving v. Virginia, 388 U. S. 1, 11 (1967).
The State, of course, has a duty of the highest order to protect the interests of minor children, particularly those of tender years. In common with most states, Florida law mandates that custody determinations be made in the best interests of the children involved. Fla. Stat. § 61.13(2)(b)(l) (1983). The goal of granting custody based on the best interests of the child is indisputably a substantial governmental interest for purposes of the Equal Protection Clause.
It would ignore reality to suggest that racial and ethnic prejudices do not exist or that all manifestations of those prejudices have been eliminated. There is a risk that a child living with a stepparent of a different race may be subject to a variety of pressures and stresses not present if the child were living with parents of the same racial or ethnic origin.
The question, however, is whether the reality of private biases and the possible injury they might inflict are permissible considerations for removal of an infant child from the custody of its natural mother. We have little difficulty concluding that they are not. The Constitution cannot control such prejudices but neither can it tolerate them. Private biases may be outside the reach of the law, but the law cannot, directly or indirectly, give them effect. “Public officials sworn to uphold the Constitution may not avoid a constitutional duty by bowing to the hypothetical effects of private racial prejudice that they assume to be both widely and deeply held.” Palmer v. Thompson, 403 U. S. 217, 260-261 (1971) (White, J., dissenting).
This is by no means the first time that acknowledged racial prejudice has been invoked to justify racial classifications. In Buchanan v. Warley, 245 U. S. 60 (1917), for example, this Court invalidated a Kentucky law forbidding Negroes to buy homes in white neighborhoods.
“It is urged that this proposed segregation will promote the public peace by preventing race conflicts. Desirable as this is, and important as is the preservation of the public peace, this aim cannot be accomplished by laws or ordinances which deny rights created or protected by the Federal Constitution.” Id., at 81.
Whatever problems racially mixed households may pose for children in 1984 can no more support a denial of constitutional rights than could the stresses that residential integration was thought to entail in 1917. The effects of racial prejudice, however real, cannot justify a racial classification removing an infant child from the custody of its natural mother found to be an appropriate person to have such custody.
The judgment of the District Court of Appeal is reversed.
It is so ordered.
The actions of state courts and judicial officers in their official capacity have long been held to be state action governed by the Fourteenth Amendment. Shelley v. Kraemer, 334 U. S. 1 (1948); Ex parte Virginia, 100 U. S. 339, 346-347 (1880).
In light of our holding based on the Equal Protection Clause, we need not reach or resolve petitioner’s claim based on the Fourteenth Amendment’s Due Process Clause.
This conclusion finds support in other cases as well. For instance, in Watson v. Memphis, 373 U. S. 526 (1963), city officials claimed that desegregation of city parks had to proceed slowly to “prevent interracial disturbances, violence, riots, and community confusion and turmoil.” Id., at 535. The Court found such predictions no more than “personal speculations or vague disquietudes,” id., at 536, and held that “constitutional rights may not be denied simply because of hostility to their assertion or exercise,” id., at 535. In Wright v. Georgia, 373 U. S. 284 (1963), the Court reversed a Negro defendant’s breach-of-peace conviction, holding that “the possibility of disorder by others cannot justify exclusion of persons from a place if they otherwise have a constitutional right (founded upon the Equal Protection Clause) to be present.” Id., at 293.