OPINION OF THE COURT
ADAMS, Circuit Judge.This is the third time that the petitioner’s request for the convening of a three-judge court has been before us. Previously, this Court decided that the cause of action involved a “substantial federal question.”1 Now we must determine whether the complaint alleges a basis for granting equitable relief.
A.
The petition for summary reversal relates, and the respondents do not deny, the following statement of the case: Adam Chlystek was divorced from his wife on the ground of his adultery. For the last thirty-five years he has lived with Helen Chlystek, the co-respondent in the divorce action. Under the relevant Pennsylvania statutes it would appear that Adam and Helen may not marry or obtain a marriage license so long as the former Mrs. Chlystek is alive.2 Unless their cohabitation is recognized as a marriage, Helen will be denied Social Security benefits either as Adam’s wife or as his widow. Consequently, in order to legitimate their relationship, the Chlysteks have come to the federal courts seeking an injunction against the enforcement of the applicable Pennsylvania statutes and a declaration that such statutes are unconstitutional. To obtain this equitable relief, they asked the district judge to convene a three-judge court pursuant to 28 U.S.C. §§ 2281 and 2284.
B.
The district court initially refused to call for a three-judge tribunal on the ground that the Chlysteks did not present a substantial federal question. Although mandamus was denied the Chlysteks, this Court subsequently reversed the decision of the district court and ordered it to request a three-judge court, if “the other conditions precedent to convening a three-judge court were satisfied, i. e., whether the complaint formally alleged a basis for equitable relief and whether the action sought to enjoin a state official from executing a statute of statewide application.”3
On remand the district court found that the action did seek to enjoin a state official, the Register of Wills of Allegheny County, from executing a statute of statewide application. The district court, however, declined to ask the Chief Judge to convene a three-judge court because he stated, remedies other than an injunction were available, specifically a proceeding under the Pennsylvania Declaratory Judgment Act or, in the alternative, a federal declaratory judgment. Central to the denial was the district court’s belief that “the state courts are the more appropriate forum in view of the questions presented involving interpretation of state statutes and public policy.” In addition, the entire action was dismissed without consideration of the prayer for a federal declaratory judgment.
C.
The duty of a district judge in considering an application for a statutory *173three-judge court is set forth in Idlewild Bon Voyage Liquor Corp. v. Epstein.4
[T]he court’s inquiry is appropriately limited to determining whether the constitutional question raised is substantial, whether the complaint at least formally alleges a basis for equitable relief, and whether the case presented otherwise comes within the requirement of the three-judge statute.
With respect to whether a substantial federal question is present, we are governed by the law-of-the-case doctrine. With respect to whether an injunction against a state officer enforcing a law of statewide application is involved, we are bound by the determination of the district court, which has not been appealed. The sole remaining issue therefore, is whether the complaint alleged an adequate basis for equitable relief. The district court ruled that it did not, and its conclusion was bottomed on the existence of what it considered to be adequate alternative remedies at law. We cannot agree with the district court’s analysis in this regard.
The current state of the law of Pennsylvania would not appear to provide any relief to the Chlysteks.5 Moreover, the availability of a state adjudication of the consistency between the Pennsylvania statutes and the federal constitution cannot preclude resort to the federal courts, since the Supreme Court has declared:
Congress imposed the duty upon all levels of the federal judiciary to give due respect to a suitor’s choice of a federal forum for the hearing and decision of his federal constitutional claims. Plainly, escape from that duty is not permissible merely because the state courts also have the solemn responsibility, equally with the federal courts, “ . . .to guard, enforce, and protect every right granted or secured by the Constitution of the United States.”6
When an injunction requiring the convening of a three-judge court is requested, the Supreme Court has not regarded the availability of declaratory relief as an alternative and adequate remedy at law which would preclude a grant of equitable relief and thus provide a predicate for refusing to convene a three-judge statutory court.7 As *174the Supreme Court observed in Great Lakes Co. v. Huffman, a suit for a declaratory judgment is “essentially an equitable cause of action.”8 Thus, a declaratory judgment can hardly be treated as an alternative remedy at law, as that concept has been understood, the existence of which would in itself make the issuance of an injunction inappropriate. Nor does there appear to be any basis for regarding declaratory relief as providing a remedy as complete as that offered by an injunction. This is so because, although a declaratory judgment will provide the same relief as an injunction if it is heeded, its force depends primarily on voluntary compliance by the defendant. By its nature, declaratory relief does not furnish the assurance of obedience that is contained in the contempt sanction of an injunction. To a party suffering irreparable harm from the present and continuing enforcement of a state statute, a mere declaration of rights might prove inadequate.
More significantly, the question for the district court is not whether equitable relief should issue, but whether the complaint on its face alleges a sufficient basis for such relief. The availability of a declaratory judgment and stipulations of compliance may properly affect the ultimate decision of the three-judge court,9 but the single district judge is confined in his adjudication to the formal allegations of the complaint10 and may not speculate about possible subsequent stipulations or voluntary action by the defendant.11
Accordingly, the judgment will be reversed and the cause remanded to the district court for proceedings consistent with this opinion.12
. The Court has also denied a petition for mandamus to require the convening of a three-judge court.
. 48 Pa.Stat. § 169 (Supp.1976-77); 48 Pa.Stat. § l-5(h) (1965).
. 529 F.2d 511 (3d Cir. 1975) (Table).
. 370 U.S. 713, 715, 82 S.Ct. 1294, 1296, 8 L.Ed.2d 794 (1962); see Gonzalez v. Automatic Employees Credit Union, 419 U.S. 90, 94, 95 S.Ct. 289, 42 L.Ed.2d 249 (1974).
. See In re Estate of Lenherr, 455 Pa. 225, 314 A.2d 255 (1974), where the Pennsylvania Supreme Court recently held that 48 Pa.Stat. § 1-5(h) applied to all divorces on the ground of adultery, not just to those which also involved a conviction for “the crime of adultery,” as might be inferred from the statutory language. In addition, the Supreme Court held that section 169 precluded legitimation of the cohabitation of a divorced spouse and his co-respondent by a common-law marriage. 455 Pa., at 228 n. 1, 314 A.2d at 257 n. 1.
. Zwickler v. Koota, 389 U.S. 241, 248, 88 S.Ct. 391, 395, 19 L.Ed.2d 444 (1967); Lake Carriers Ass’n v. MacMullan, 406 U.S. 498, 92 S.Ct. 1749, 32 L.Ed.2d 257 (1972).
. E. g., Planned Parenthood of Central Mo. v. Danforth, - U.S. -, 96 S.Ct. 2831, 49 L.Ed. - (1976).
Although we sympathize with the district court’s motive in seeking to avoid an onerous and perhaps disruptive three-judge court proceeding, to permit the denial of such a court, when injunctive relief pursuant to section 2281 is requested, because a declaratory judgment provides the “same relief” would countenance an improper circumvention of the three-judge court statute. Congress enacted the three-judge court procedure in order to prevent one judge alone from deciding that a statute was unconstitutional and enjoining the enforcement of such statute. If a single district judge may refuse to call for a three-judge court on the basis of the availability in the alternative of a declaratory judgment, the single judge could then render a judgment on the constitutionality of the disputed state law and subsequently request a three-judge court to enforce that declaration by an injunction pursuant to section 2202. The three-judge court, however, would seem to be precluded from reconsidering the constitutionality of the statute because of the res judicata effect of the prior declaratory judgment. See King v. United States, 390 F.2d 894, 906, 182 Ct.Cl. 631 (1968) (dictum), rev’d on other grounds, 395 U.S. 1, 89 S.Ct. 1501, 23 L.Ed.2d 52 (1969). Thus, the three-judge court, far from providing special consideration prior to a determination that an injunction should issue because a statute is unconstitutional, as Congress intended, would be substantially barred from the role contemplated by Congress. See Currie, The Three-Judge District Court in Constitutional Litigation, 32 U.Chi.L. *174Rev. 1, 15-19 and n. 102 (1964). But see Note, Judicial Limitation of Three-Judge Court Jurisdiction, 85 Yale L.J. 564 (1976).
. We do not, of course, express any opinion regarding the merits of the dispute.
. 319 U.S. 293, 300, 63 S.Ct. 1070, 1074, 87 L.Ed. 1407 (1943). See Samuels v. Mackell, 401 U.S. 66, 69-73, 91 S.Ct. 764, 27 L.Ed.2d 688 (1971).
. See, e. g., Doe v. Beal, 523 F.2d 611, 613 n. 1 (3d Cir. 1975), petition for cert, granted, - U.S.-, 96 S.Ct. 3220, 49 L.Ed.2d-(1975).
. 370 U.S. at 715, 82 S.Ct. 1294.
. Even if the district court were correct in declining to convene a three-judge district court, it was improper for it to dismiss the case without at the very least considering the Chlysteks’ request for a declaratory judgment. The Chlysteks are not obliged to resort to a state forum for such relief, see note 6 and accompanying text, and their cause seems to present “a substantial controversy, between parties having adverse legal interests, of sufficient immediacy and reality to warrant the issuance of a declaratory judgment.” Maryland Cas. Co. v. Pacific Coal & Oil Co., 312 U.S. 270, 273, 61 S.Ct. 510, 512, 85 L.Ed. 826 (1941).