Mr. Justice Brennan
delivered the opinion of the Court.
Appellee William Baird was convicted at a bench trial in the Massachusetts Superior Court under Massachusetts General Laws Ann., c. 272, § 21, first, for exhibiting contraceptive articles in the course of delivering a lecture on contraception to a group of students at Boston University and, second, for giving a young woman a package of Emko vaginal foam at the close of his address. The Massachusetts Supreme Judicial Court unanimously set aside the conviction for exhibiting contraceptives on the ground that it violated Baird’s First Amendment rights, but by a four-to-three vote sustained the conviction for giving away the foam. Commonwealth v. Baird, 355 Mass. 746, 247 N. E. 2d 574 (1969). Baird subsequently filed a petition for a federal writ of habeas corpus, which the District Court dismissed. 310 F. Supp. 951 (1970). On appeal, however, the Court of Appeals for the First Circuit vacated the dismissal and remanded the action with directions to grant the writ discharging Baird. 429 F. 2d 1398 (1970). This appeal by the Sheriff of Suffolk County, Massachusetts, followed, and we noted probable jurisdiction. 401 U. S. 934 (1971). We affirm.
Massachusetts General Laws Ann., c. 272, § 21, under which Baird was convicted, provides a maximum five-year term of imprisonment for “whoever . . . gives away . . . any drug, medicine, instrument or article whatever for the prevention of conception,” except as authorized in § 21A. Under § 21 A, “[a] registered physician may administer to or prescribe for any married person drugs or articles intended for the prevention of pregnancy or conception. [And a] registered pharmacist actually engaged in the business of pharmacy may furnish such drugs or articles to any married person presenting a prescription from a registered physician.” As interpreted by the State Supreme Judicial Court, these provisions make it a felony for anyone, other than a registered physician or pharmacist acting in accordance with the terms of § 21A, to dispense any article with the intention that it be used for the prevention of conception. The statutory scheme distinguishes among three distinct classes of distributees — first, married persons may obtain contraceptives to prevent pregnancy, but only from doctors or druggists on prescription; second, single persons may not obtain contraceptives from anyone to prevent pregnancy; and, third, married or single persons may obtain contraceptives from anyone to prevent, not pregnancy, but the spread of disease. This construction of state law is, of course, binding on us. E. g., Groppi v. Wisconsin, 400 U. S. 505, 507 (1971).
The legislative purposes that the statute is meant to serve are not altogether clear. In Commonwealth v. Baird, supra, the Supreme Judicial Court noted only the State’s interest in protecting the health of its citizens: “[T]he prohibition in §21,” the court declared, “is directly related to” the State’s goal of “preventing the distribution of articles designed to prevent conception which may have undesirable, if not dangerous, physical consequences.” 355 Mass., at 753, 247 N. E. 2d, at 578. In a subsequent decision, Sturgis v. Attorney General, 358 Mass. 37, -, 260 N. E. 2d 687, 690 (1970), the court, however, found “a second and more compelling ground for upholding the statute” — namely, to protect morals through “regulating the private sexual lives of single persons.” The Court of Appeals, for reasons that will appear, did not consider the promotion of health or the protection of morals through the deterrence of fornication to be the legislative aim. Instead, the court concluded that the statutory goal was to limit contraception in and of itself — a purpose that the court held conflicted “with fundamental human rights” under Griswold v. Connecticut, 381 U. S. 479 (1965), where this Court struck down Connecticut’s prohibition against the use of contraceptives as an unconstitutional infringement of the right of marital privacy. 429 F. 2d, at 1401-1402.
We agree that the goals of deterring premarital sex and regulating the distribution of potentially harmful articles cannot reasonably be regarded as legislative aims of §§21 and 21 A. And we hold that the statute, viewed as a prohibition on contraception per se, violates the rights of single persons under the Equal Protection Clause of the Fourteenth Amendment.
I
We address at the outset appellant’s contention that Baird does not have standing to assert the rights of unmarried persons denied access to contraceptives because he was neither an authorized distributor under § 21A nor a single person unable to obtain contraceptives. There can be no question, of course, that Baird has sufficient interest in challenging the statute’s validity to satisfy the “case or controversy” requirement of Article III of the Constitution. Appellant’s argument, however, is that this case is governed by the Court’s self-imposed rules of restraint, first, that “one to whom application of a statute is constitutional will not be heard to attack the statute on the . ground that impliedly it might also be taken as applying to other persons or other situations in which its application might be unconstitutional,” United States v. Raines, 362 U. S. 17, 21 (1960), and, second, the “closely related corollary that a litigant may only assert his own constitutional rights or immunities,” id., at 22. Here, appellant contends that Baird’s conviction rests on the restriction in § 21A on permissible distributors and that that restriction serves a valid health interest independent of the limitation on authorized distributees. Appellant urges, therefore, that Baird’s action in giving away the foam fell squarely within the conduct- that the legislature meant and had power to prohibit and that Baird should not be allowed to attack the statute in its application to potential recipients. In any event, appellant concludes, since Baird was not himself a single person denied access to contraceptives, he should not be heard to assert their rights. We cannot agree.
The Court of Appeals held that the statute under which Baird was convicted is not a health measure. If that view is correct, we do not see how Baird may be prevented, because he was neither a doctor nor a druggist, from attacking the statute in its alleged discriminatory application to potential distributees. We think, too, that our self-imposed rule against the assertion of third-party rights must be relaxed in this case just as in Griswold v. Connecticut, supra. There the Executive Director of the Planned Parenthood League of Connecticut and a licensed physician who had prescribed contraceptives for married persons and been convicted as accessories to the crime of using contraceptives were held to have standing to raise the constitutional rights of the patients with whom they had a professional relationship. Appellant herPargues that the absence of a professional or aiding^aSM-abetting relationship distinguishes this case from (jmswold. 'Yet, as the Court’s discussion of prior authority in Griswold, 381 U. S., at 481, indicates, the doctor-patient and accessory-principal relationships are not the only circumstances in which one person has been found to have standing to assert the rights of another. Indeed, in Barrows v. Jackson, 346 U. S. 249 (1953), a seller of land was entitled to defend against an action for damages for breach of a racially restrictive covenant on the ground that enforcement of the covenant violated the equal protection rights of prospective non-Caucasian purchasers. The relationship there between the defendant and those whose rights he sought to assert was not simply the fortuitous connection between a vendor and potential vendees, but the relationship between one who acted to protect the rights of a minority and the minority itself. Sedler, Standing to Assert Constitutional Jus Tertii in the Supreme Court, 71 Yale L. J. 599, 631 (1962). And so here the relationship between Baird and those whose rights he seeks to assert is not simply that between a distributor and potential distributees, but that between an advocate of the rights of persons to obtain contraceptives and those desirous of doing so. The very point of Baird’s giving away the vaginal foam was to challenge the Massachusetts statute that limited access to contraceptives.
In any event, more important than the nature of the relationship between the litigant and those whose rights he seeks to assert is the impact of the litigation on the third-party interests. In Griswold, 381 U. S., at 481, the Court stated: “The rights of husband and wife, pressed here, are likely to be diluted or adversely affected unless those rights are considered in a suit involving those who have this kind of confidential relation to them.” A similar situation obtains here. Enforcement of the Massachusetts statute will materially impair the ability of single persons to obtain contraceptives. In fact, the case for according standing to assert third-party rights is stronger in this regard here than in Griswold because unmarried persons denied access to contraceptives in Massachusetts, unlike the users of contraceptives in Connecticut, are not themselves subject to prosecution and, to that extent, are denied a forum in which to assert their own rights. Cf. NAACP v. Alabama, 357 U. S. 449 (1958); Barrows v. Jackson, supra. The Massachusetts statute, unlike the Connecticut law considered in Gris-wold, prohibits, not use, but distribution.
For the foregoing reasons we hold that Baird, who is now in a position, and plainly has an adequate incentive, to assert the rights of unmarried persons denied access to contraceptives, has standing to do so. We turn to the merits.
II
The basic principles governing application of the Equal Protection Clause of the Fourteenth Amendment are familiar. As The Chief Justice only recently explained in Reed v. Reed, 404 U. S. 71, 75-76 (1971):
“In applying that clause, this Court has consistently recognized that the Fourteenth Amendment does not deny to States the power to treat different classes of persons in different ways. Barbier v. Connolly, 113 U. S. 27 (1885); Lindsley v. Natural Carbonic Gas Co., 220 U. S. 61 (1911); Railway Express Agency v. New York, 336 U. S. 106 (1949); McDonald v. Board of Election Commissioners, 394 U. S. 802 (1969). The Equal Protection Clause of that amendment does, however, deny to States the power to legislate that different treatment be accorded to persons placed by a statute into different classes on the basis of criteria wholly unrelated to the objective of that statute. A classification 'must be reasonable, not arbitrary, and must rest upon some ground of difference having a fair and substantial relation to the object of the legislation, so that all persons similarly circumstanced shall be treated alike.’ Royster Guano Co. v. Virginia, 253 U. S. 412, 415 (1920).”
The question for our determination in this case is whether there is some ground of difference that rationally explains the different treatment accorded married and unmarried persons under Massachusetts General Laws Ann., c. 272, §§21 and 21 A. For the reasons that follow, we conclude that no such ground exists.
First. Section 21 stems from Mass. Stat. 1879, c. 159, § 1, which prohibited, without exception, distribution of articles intended to be used as contraceptives. In Commonwealth v. Allison, 227 Mass. 57, 62, 116 N. E. 265, 266 (1917), the Massachusetts Supreme Judicial Court explained that the law’s “plain purpose is to protect purity, to preserve chastity, to encourage continence and self restraint, to defend the sanctity of the home, and thus to engender in the State and nation a virile and virtuous race of men and women.” Although the State clearly abandoned that purpose with the enactment of § 21A, at least insofar as the illicit sexual activities of married persons are concerned, see n. 3, supra, the court reiterated in Sturgis v. Attorney General, supra, that the object of the legislation is to discourage premarital sexual intercourse. Conceding that the State could, consistently with the Equal Protection Clause, regard the problems of extramarital and premarital sexual relations as “[e] vils ... of different dimensions and proportions, requiring different remedies,” Williamson v. Lee Optical Co., 348 U. S. 483, 489 (1955), we cannot agree that the deterrence of premarital sex may reasonably be regarded as the purpose of the Massachusetts law.
It would be plainly unreasonable to assume that Massachusetts has prescribed pregnancy and the birth of an unwanted child as punishment for fornication, which is a misdemeanor under Massachusetts General Laws Ann., c. 272, § 18. Aside from the scheme of values that assumption would attribute to the State, it is abundantly clear that the effect of the ban on distribution of contraceptives to unmarried persons has at best a marginal relation to the proffered objective. What Mr. Justice Goldberg said in Griswold v. Connecticut, supra, at 498 (concurring opinion), concerning the effect of Connecticut’s prohibition on the use of contraceptives in discouraging extramarital sexual relations, is equally applicable here. “The rationality of this justification is dubious, particularly in light of the admitted widespread availability to all persons in the State of Connecticut, unmarried as well as married, of birth-control devices for the prevention of disease, as distinguished from the prevention of conception.” See also id., at 505-507 (White, J., concurring in judgment). Like Connecticut’s laws, §§21 and 21A do not at all regulate the distribution of contraceptives when they are to be used to prevent, not pregnancy, but the spread of disease. Commonwealth v. Corbett, 307 Mass. 7, 29 N. E. 2d 151 (1940), cited with approval in Commonwealth v. Baird, 355 Mass., at 754, 247 N. E. 2d, at 579. Nor, in making contraceptives available to married persons without regard to their intended use, does Massachusetts attempt to deter married persons from engaging in illicit sexual relations with unmarried persons. Even on the assumption that the fear of pregnancy operates as a deterrent to fornication, the Massachusetts statute is thus so riddled with exceptions that deterrence of premarital sex cannot reasonably be regarded as its aim.
Moreover, §§21 and 21A on their face have a dubious relation to the State’s criminal prohibition on fornication. As the Court of Appeals explained, “Fornication is a misdemeanor [in Massachusetts], entailing a thirty dollar fine, or three months in jail. Massachusetts General Laws Ann. c. 272 § IS. Violation of the present statute is a felony, punishable by five years in prison. We find it hard to believe that the legislature adopted a statute carrying a five-year penalty for its possible, obviously by no means fully effective, deterrence of the commission of a ninety-day misdemeanor.” 429 F. 2d, at 1401. Even conceding the legislature a full measure of discretion in fashioning means to prevent fornication, and recognizing that the State may seek to deter prohibited conduct by punishing more severely those who facilitate than those who actually engage in its commission, we, like the Court of Appeals, cannot believe that in this instance Massachusetts has chosen to expose the aider and abetter who simply gives away a contraceptive to 20 times the 90-day sentence of the offender himself. The very terms of the State’s criminal statutes, coupled with the de minimis effect of §§21 and 21A in deterring fornication, thus compel the conclusion that such deterrence cannot reasonably be taken as the purpose of the ban on distribution of contraceptives to unmarried persons.
Second. Section 21A was added to the Massachusetts General Laws by Stat. 1966, c. 265, § 1. The Supreme Judicial Court in Commonwealth v. Baird, supra, held that the purpose of the amendment was to serve the health needs of the community by regulating the distribution of potentially harmful articles. It is plain that Massachusetts had no such purpose in mind before the enactment of § 21A. As the Court of Appeals remarked, “Consistent with the fact that the statute was contained in a chapter dealing with ‘Crimes Against Chastity, Morality, Decency and Good Order,’ it was cast only in terms of morals. A physician was forbidden to prescribe contraceptives even when needed for the protection of health. Commonwealth v. Gardner, 1938, 300 Mass. 372, 15 N. E. 2d 222.” 429 F. 2d, at 1401. Nor did the Court of Appeals “believe that the legislature [in enacting § 21A] suddenly reversed its field and developed an interest in health. Rather, it merely made what it thought to be the precise accommodation necessary to escape the Griswold ruling.” Ibid.
Again, we must agree with the Court of Appeals. If health were the rationale of § 21A, the statute would be both discriminatory and overbroad. Dissenting in Commonwealth v. Baird, 355 Mass., at 758, 247 N. E. 2d, at 581, Justices Whittemore and Cutter stated that they saw “in § 21 and § 21A, read together, no public health purpose. If there is need to have a physician prescribe (and a pharmacist dispense) contraceptives, that need is as great for unmarried persons as for married persons.” The Court of Appeals added: “If the prohibition [on distribution to unmarried persons] ... is to be taken to mean that the same physician who can prescribe for married patients does not have sufficient skill to protect the health of patients who lack a marriage certificate, or who may be currently divorced, it is illogical to the point of irrationality.” 429 F. 2d, at 1401. Furthermore, we must join the Court of Appeals in noting that not all contraceptives are potentially dangerous. As a result, if the Massachusetts statute were a health measure, it would not only invidiously discriminate against the unmarried, but also be overbroad with respect to the married, a fact that the Supreme Judicial Court itself seems to have conceded in Sturgis v. Attorney General, 358 Mass., at -, 260 N. E. 2d, at 690, where it noted that “it may well be that certain contraceptive medication and devices constitute no hazard to health, in which event it could be argued that the statute swept too broadly in its prohibition.” “In-this posture,” as the Court of Appeals concluded, “it is impossible to think of the statute as intended as a health measure for the unmarried, and it is almost as difficult to think of it as so intended even as to the married.” 429 F. 2d, at 1401.
But if further proof that the Massachusetts statute is not a health measure is necessary, the argument of Justice Spiegel, who also dissented in Commonwealth v. Baird, 355 Mass., at 759, 247 N. E. 2d, at 582, is conclusive : “It is at best a strained conception to say that the Legislature intended to prevent the distribution of articles 'which may have undesirable, if not dangerous, physical consequences.’ If that was the Legislature’s goal, § 21 is not required” in view of the federal and state laws already regulating the distribution of harmful drugs. See Federal Food, Drug, and Cosmetic Act, § 503, 52 Stat. 1051, as amended, 21 U. S. C. § 353; Mass. Gen. Laws Ann., c. 94, § 187A, as amended. We conclude, accordingly, that, despite the statute’s superficial earmarks as a health measure, health, on the face of the statute, may no more reasonably be regarded as its purpose than the deterrence of premarital sexual relations.
Third. If the Massachusetts statute cannot be upheld as a deterrent to fornication or as a health measure, may it, nevertheless, be sustained simply as a prohibition on contraception? The Court of Appeals analysis “led inevitably to the conclusion that, so far as morals are concerned, it is contraceptives per se that are considered immoral — to thq extent that Griswold will permit such a declaration.” 429 F. 2d, at 1401-1402. The Court of Appeals went on to hold, id., at 1402:
“To say that contraceptives are immoral as such, and are to be forbidden to unmarried persons who will nevertheless persist in having intercourse, means that such persons must risk for themselves an unwanted pregnancy, for the child, illegitimacy, and for society, a possible obligation of support. Such a view of morality is not only the very mirror image of sensible legislation; we consider that it conflicts with fundamental human rights. In the absence of demonstrated harm, we hold it is beyond the competency of the state.”
We need not and do not, however, decide that important question in this case because, whatever the rights of the individual to access to contraceptives may be, the rights must be the same for the unmarried and the married alike.
If under Griswold the distribution of contraceptives to married persons cannot be prohibited, a ban on distribution to unmarried persons would be equally impermissible. It is true that in Griswold the right of privacy in question inhered in the marital relationship. Yet the \ marital couple is not an independent entity with a mind . and heart of its own, but an association of two individ- | uals each with a separate intellectual and emotional / makeup. If the right of privacy means anything, it is j the right of the individual, married or single, to be free j from unwarranted governmental intrusion into matters] so fundamentally affecting a person as the decision] whether to bear or beget a child. See Stanley v. Georgia, 394 U. S. 557 (1969). See also Skinner v. Okla homa, 316 U. S. 535 (1942); Jacobson v. Massachusetts, 197 U. S. 11, 29 (1905).
On the other hand, if Griswold is no bar to a prohibition on the distribution of contraceptives, the State could not, consistently with the Equal Protection Clause, outlaw distribution to unmarried but not to married persons. In each case the evil, as perceived by the State, would be identical, and the underinclusion would be invidious. Mr. Justice Jackson, concurring in Railway Express Agency v. New York, 336 U. S. 106, 112-113 (1949), made the point:
“The framers of the Constitution knew, and we should not forget today, that there is no more effective practical guaranty against arbitrary and unreasonable government than to require that the principles of law which officials would impose upon a minority must be imposed generally. Conversely, nothing opens the door to arbitrary action so effectively as to allow those officials to pick and choose only a few to whom they will apply legislation and thus to escape the political retribution that might be visited upon them if larger numbers were affected. Courts can take no better measure to assure that laws will be just than to require that laws be equal in operation.”
Although Mr. Justice Jackson’s comments had reference to administrative regulations, the principle he affirmed has equal application to the legislation here. We hold that by providing dissimilar treatment for married and unmarried persons who are similarly situated, Massachusetts General Laws Ann., c. 272, §§21 and 21 A, violate the Equal Protection Clause. The judgment of the Court of Appeals is
Affirmed.
Mr. Justice Powell and Mr. Justice Rehnquist took no part in the consideration or decision of this case.
The Court of Appeals below described the recipient of the foam as “an unmarried adult woman.” 429 F. 2d 1398, 1399 (1970). However, there is no evidence in the record about her marital status.
Section 21 provides in full:
“Except as provided in section twenty-one A, whoever sells, lends, gives away, exhibits or offers to sell, lend or give away an instrument or other article intended to be used for self-abuse, or any drug, medicine, instrument or article whatever for the prevention of conception or for causing unlawful abortion, or advertises the same, or writes, prints, or causes to be written or printed a card, circular, book, pamphlet, advertisement or notice of any kind stating when, where, how, of whom or by what means such article can be purchased or obtained, or manufactures or makes any such article shall be punished by imprisonment in the state prison for not more than five years or in jail or the house of correction for not more than two and one half years or by a fine of not less than one hundred nor more than one thousand dollars.”
Section 21A provides in full:
“A registered physician may administer to or prescribe for any married person drugs or articles intended for the prevention of pregnancy or conception. A registered pharmacist actually engaged in the business of pharmacy may furnish such drugs or articles to any married person presenting a prescription from a registered physician.
“A public health agency, a registered nurse, or a maternity health clinic operated by or in an accredited hospital may furnish information to any married person as to where professional advice regarding such drugs or articles may be lawfully obtained.
“This section shall not be construed as affecting the provisions of sections twenty and twenty-one relative to prohibition of advertising of drugs or articles intended for the prevention of pregnancy or conception; nor shall this section be construed so as to permit the sale or dispensing of such drugs or articles by means of any vending machine or similar device.”
Appellant suggests that the purpose of the Massachusetts statute is to promote marital fidelity as well as to discourage premarital sex. Under § 21A, however, contraceptives may be made available to married persons without regard to whether they are living with their spouses or the uses to which the contraceptives are to be put. Plainly the legislation has no deterrent effect on extramarital sexual relations.
This factor decisively distinguishes Tileston v. Ullman, 318 U. S. 44 (1943), where the Court held that a physician lacked standing to bring an action for declaratory relief to challenge, on behalf of his patients, the Connecticut law prohibiting the use of contraceptives. The patients were fully able to bring their own action. Underlying the decision was the concern that “the standards of 'case or controversy’ in Article III of the Constitution [not] become blurred,” Griswold v. Connecticut, 381 U. S. 479, 481 (1965)— a problem that is not at all involved in this ease.
Indeed, in First Amendment cases we have relaxed our rules of standing without regard to the relationship between the litigant and those whose rights he seeks to assert precisely because application of those rules would have an intolerable, inhibitory effect on freedom of speech. E. g., Thornhill v. Alabama, 310 U. S. 88, 97-98 (1940). See United States v. Raines, 362 U. S. 17, 22 (1960).
See also Prince v. Massachusetts, 321 U. S. 158 (1944), where a custodian, in violation of state law, furnished a child with magazines to distribute on the streets. The Court there implicitly held that the custodian had standing to assert alleged freedom of religion and equal protection rights of the child that were threatened in the very litigation before the Court and that the child had no effective way of asserting herself.
Of course, if we were to conclude that the Massachusetts statute impinges upon fundamental freedoms under Griswold, the statutory classification would have to be not merely rationally related to a valid public purpose but necessary to the achievement of a compelling state interest. E. g., Shapiro v. Thompson, 394 U. S. 618 (1969); Loving v. Virginia, 388 U. S. 1 (1967). But just as in Reed v. Reed, 404 U. S. 71 (1971), we do not have to address the statute’s validity under that test because the law fails to satisfy even the more lenient equal protection standard.
Appellant insists that the unmarried have no right to engage in sexual intercourse and hence no health interest in contraception that needs to be served. The short answer to this contention is that the same devices the distribution of which the State purports to regulate when their asserted purpose is to forestall pregnancy are available without any controls whatsoever so long as their asserted purpose is to prevent the spread of disease. It is inconceivable that the need for health controls varies with the purpose for which the contraceptive is to be used when the physical act in all cases is one and the same.
The Court of Appeals stated, 429 F. 2d, at 1401:
“[W]e must take notice that not all contraceptive devices risk 'undesirable . . . [or] dangerous physical consequences.’ It is 200 years since Casanova recorded the ubiquitous article which, perhaps because of the birthplace of its inventor, he termed a ‘redingote anglais.’ The reputed nationality of the condom has now changed, but we have never heard criticism of it on the side of health. We cannot think that the legislature was unaware of it, or could have thought that it needed a medical prescription. We believe the same could be said of certain other products.”
In Stanley, 394 U. S., at 564, the Court stated:
“[A]Iso fundamental is the right to be free, except in very limited circumstances, from unwanted governmental intrusions into one’s privacy.
“ ‘The makers of our Constitution undertook to secure conditions favorable to the pursuit of happiness. They recognized the significance of man’s spiritual nature, of his feelings and of his intellect. They knew that only a part of the pain, pleasure and satisfactions of life are to be found in material things. They sought to protect Americans in their beliefs, their thoughts, their emotions and their sensations. They conferred, as against the Government, the right to be let alone — the most comprehensive of rights and the right most valued by civilized man.’ Olmstead v. United States, 277 U. S. 438, 478 (1928) (Brandeis, J., dissenting).
“See Griswold v. Connecticut, supra; cf. NAACP v. Alabama, 357 U. S. 449, 462 (1958).”