A California law defined statutory rape as sexual intercourse with a female under the age of 18 who is not the perpetrator's wife. Michael M. (defendant), a 17-year-old male, was charged with violating California’s statutory-rape law by having sexual intercourse with a 16-year-old female. He sought dismissal of his charges in California state court on the grounds that the statutory-rape law violated the Fourteenth Amendment’s Equal Protection Clause. The trial court denied his motion, and the Supreme Court of California affirmed. The state supreme court found that the statutory-rape statute discriminated on the basis of sex because only females could be victims, and only males could be charged with violating the statute. Nevertheless, the court concluded that the gender classification in the statute was justified by California's compelling state interest in preventing illegitimate teenage pregnancies. The United States Supreme Court granted certiorari.