After California issued sales and use tax deficiency notices to federal contractor Williams Brothers Engineering Company (WBEC) in 1978 and 1982, the State assessed approximately $14 million in such taxes against WBEC for the tax years 1975 through 1981. Under its contract with the United States, WBEC received an annual fixed fee plus reimbursement for costs, including the state taxes. At the Government's direction, WBEC applied to the State Board of Equalization for redetermination of the assessments, but each claim was denied, with minor exceptions. WBEC then paid the assessments under protest, using funds the Government provided, and filed timely actions in state court. In January 1988, the State and WBEC stipulated to a $3 million refund and to dismissal of the actions without prejudice. In May 1988, the Government filed suit in the Federal District Court, seeking a declaratory judgment that California had classified and taxed WBEC erroneously under state law and an $11 million refund plus interest. In granting the State summary judgment, the District Court rejected the Government's argument that it was entitled to recovery based on the federal common law cause of action for money had and received. The Court of Appeals affirmed.

Held: The Federal Government may not recover the taxes it claims were wrongfully assessed under California law against WBEC. Pp. ____.

(a) Shouldering the entire economic burden of a levy through indemnification does not give the Government a federal common law cause of action for money had and received to challenge a state tax on state-law grounds simply because it is the Government. The contract here is in all relevant respects identical to the ones discussed in United States v. New Mexico,
455 U.S. 720, 102 S.Ct. 1373, 71 L.Ed.2d 580, in which the Court held, inter alia, that federal contractors are not immune from state taxes simply because the Government reimburses all of the contractors' state tax expenditures, see
id., at 734-735, 102 S.Ct., at 1382-1383. Moreover, the Government's voluntary agreement to reimburse (or even fund in advance) WBEC for the taxes does not make the Government's payments direct disbursements of federal funds to the State. Cf. Brady v. Roosevelt Steamship Co.,
317 U.S. 575, 63 S.Ct. 425, 87 L.Ed. 471. Thus, the Government cannot use the existence of its obligation to indemnify WBEC to create the asserted federal cause of action. Bayne v. United States,
93 U.S. 642, 23 L.Ed. 997, and Gaines v. Miller,
111 U.S. 395, 4 S.Ct. 426, 28 L.Ed. 466, share two features this case lacks and therefore are inapposite. Because WBEC (1) did not steal or otherwise unlawfully take the money at issue from the Government, and (2) did not have a relationship with California that would make the State liable for WBEC's actions, the Court does not imply a contract in law between California and the Government. Without an implied contract, an action for money had and received will not lie against the State. See Bayne, supra, at 643. Pp. ____.

(b) Because it indemnified WBEC, the Government has a right to be subrogated to WBEC's claims against the State. Under traditional principles of subrogation, however, a subrogee takes no more rights than its subrogor had. In this case, WBEC dismissed its state-law actions and the state statute of limitations has run against it. The Government argues that state statutes of limitations do not apply to it, but in Guaranty Trust Co. v. United States,
304 U.S. 126, 58 S.Ct. 785, 82 L.Ed. 1224, this Court held that even if that were true, the principle did not apply when the Government acquired a right by assignment after the statute of limitations has run against the assignor.
Id., at 141-142, 58 S.Ct., at 793. Although the Government acquired a right to be subrogated to WBEC's claims when it paid the taxes, it was not subrogated to those claims until it filed this proceeding in federal court. By then, the state statute of limitations had run; thus, the Government was not subrogated to "a right free of a pre-existing infirmity."
Id., at 142, 58 S.Ct., at 793. Pp. ____.

This is another in the long line of cases, beginning with McCulloch v. Maryland, 4 U.S. (Wheat.) 316, 4 L.Ed. 579 (1819), in which the Federal Government asks this Court for relief from what it considers illegal state taxes. Unlike the typical tax immunity case, however, we are not presented with a claim that the state tax is unconstitutional; instead, the question is whether the Federal Government may recover taxes it claims were wrongfully assessed under California law against one of the Government's private contractors.

* The United States has established three Naval Petroleum Reserves in California and Wyoming, one of which is Naval Petroleum Reserve No. 1, located in Kern County, California.
10 U.S.C. 7420. First through the Department of the Navy and later through the Department of Energy, the United States contracted with Williams Brothers Engineering Company (WBEC) to manage oil drilling operations at Reserve No. 1 from 1975 to 1985. Under the contract, WBEC received an annual fixed fee plus reimbursement for costs, which the contract defined to include state sales and use taxes.

California assessed approximately $14 million in sales and use taxes, pursuant to Cal.Rev. & Tax.Code Ann. § 6384 (West 1987), against WBEC for the years 1975 through 1981. The State imfrormed WBEC of the tax deficiencies through two notices, on issued in July 1978 and the other in December 1982/ WBEC. at the direction of the United applied to the California Board of Equalization for administrative redetermination of the assessments, see Cal.Rev. & Tax.Code Ann. § 6932 (West 1987). WBEC argued that the State had misapplied its own law, taxing property that was outside the scope of § 6384. The Board of Equalization denied each claim, with minor exceptions. Thereafter, WBEC paid the assessments under protest, using funds the Federal Government provided. It then filed timely actions in state court. In January 1988, the State and WBEC stipulated to a $3 million refund, for erroneous assessments on property that WBEC had purchased and that Government personnel had installed, and to dismissal of both actions without prejudice. The remaining $11 million resulted from assessments on property that WBEC had purchased and that private subcontractors, managed by WBEC, had installed.

In May 1988, the United States filed suit in the Eastern District of California, seeking a declaratory judgment that California had classified and taxed WBEC erroneously under California law and that the taxed property actually was exempt. It sought a refund of the $11 million plus interest. In the course of the suit, the United States argued it was entitled to recovery based on the federal common law cause of action for money had and received. The District Court rejected both grounds for recovery and granted summary judgment for the State.

The Court of Appeals for the Ninth Circuit affirmed. 932 F.2d 1346 (1991). The court began by noting that the Government did not claim that either it or WBEC was constitutionally immune from the tax, an argument this Court rejected in United States v. New Mexico,
455 U.S. 720, 102 S.Ct. 1373, 71 L.Ed.2d 580 (1982). 932 F.2d, at 1347-1348. Because the United States lacked "a colorable constitutional challenge,"
id., at 1349, the Court of Appeals looked to whether federal common law might provide a cause of action. It declined to accept the Government's argument that the simple act of disbursing federal funds was a "constitutional function" that created a federal interest in conflict with state law. The Government had done no more than pay state taxes pursuant to state law; this did not rise to the level of a federal interest requiring the application of federal law. Ibid. The Court of Appeals then held that the Government could not maintain a quasi-contract cause of action because the facts did not support a claim of unjust enrichment. Among other things, "WBEC, backed throughout by the United States, had a fair chance to argue against the validity of the assessments in the administrative and state court proceedings." Id., at 1350. Finally, the Court of Appeals relied on the fact that the Government's quasi-contract argument was "posited upon the interpretation of a state-created exemption from a state-created sales tax." Ibid. The court found that the State's claim filing requirements, including that a court action be filed within 90 days of an administrative denial, were conditions precedent to a cause of action for a tax refund. Id., at 1350-1351. The Government had failed to satisfy the conditions; therefore, the Court of Appeals held, the Government had no state cause of action and no quasi-contract action. "Since federal statutes of limitations become determinative only after the government acquires a cause of action, and since the United States never acquired a cause of action," the court reasoned, the six-year statute of limitations of "
28 U.S.C. 2415 does not apply." Id., at 1351.

The Court of Appeals acknowledged that the Court of Appeals for the Eleventh Circuit, in a factually similar case, recently had reached the opposite conclusion. Id., at 1351-1352. In United States v. Broward County, 901 F.2d 1005 (1990), the Eleventh Circuit rejected the argument on which the Ninth Circuit relied and held that the Government had a "federal common law cause of action in quasi-contract for money had and received." Id., at 1008-1009. We granted certiorari to resolve the conflict. 506 U.S. ----,
113 S.Ct. 50, 121 L.Ed.2d 20 (1992).

II

The Government concedes that it could have intervened in WBEC's administrative and state court proceedings. Tr. of Oral Arg. 17. But it argues that whether it complied with state procedural requirements or whether it could have intervened is irrelevant, because it has a federal right to recover the taxes under the federal common law cause of action for money had and received (also known as indebitatus assumpsit ). Prior to the creation of federal administrative and statutory remedies for the recovery of federal taxes, this Court held that a taxpayer could bring an action for money had and received to recover erroneously or illegally assessed taxes. In City of Philadelphia v. The Collector, 72 U.S. (5 Wall.) 720, 18 L.Ed. 614 (1867), the Court stated:

"The appropriate remedy to recover back money paid to federal tax collectors under protest on account of duties or taxes erroneously or illegally assessed, is an action of assumpsit for money had and received. Where the party voluntarily pays the money, he is without remedy; but if he pays it by compulsion of law, or under protest, or with notice that he intends to bring suit to test the validity of the claim, he may recover it back, if the assessment was erroneous or illegal, in an action of assumpsit for money had and received." Id., at 731-732 (citing Elliott v. Swartout, 35 U.S. (10 Pet.) 137, 150, 9 L.Ed. 373 (1836)).

The Government reasons that it paid WBEC's taxes, that the taxes were wrongfully assessed, and that therefore it may recover the funds used to pay those taxes. Since an action for money had and received is based on a contract implied in law, see Bayne v. United States,
93 U.S. 642, 643, 23 L.Ed. 997 (1876), the Government further reasons that its claims are governed by the 6-year statute of limitations in
28 U.S.C. 2415(a), and not the 90-day limitation period in the California Code.

The taxpayers in both City of Philadelphia and the case on which it relies, Elliott v. Swartout, were attempting to recover money they had paid under protest to the federal tax collector in settlement of tax assessments erroneously made against them. In this case, by contrast, the taxpayerWBEC has had its day in court and gone home. The Government attempts to recover money it paid in reimbursement for state tax assessments against the contractor, even though the contractor already has challenged the assessment and accepted a resolution of its claims. The Government contends that, because its contract with WBEC involved an advanced funding arrangement, the Government was the one that actually paid the state taxes. Because the disbursement of federal funds is involved, the Government asserts, the federal action for money had and received is appropriate. Even assuming that federal courts may entertain a federal common law action for the recovery of state taxes paid by the Government, we conclude that a federal action is inappropriate here because the Government is in no better position than as a subrogee of its contractor WBEC.

The management contract between the Government and WBEC is in all relevant respects identical to the contracts we discussed in United States v. New Mexico,
455 U.S. 720, 102 S.Ct. 1373, 71 L.Ed.2d 580 (1982). There, as here, the State had imposed sales and use taxes on private contractors managing Department of Energy sites. Like WBEC, two of the contractors received costs plus a fixed fee.
Id., at 723-724, 102 S.Ct., at 1377. Like WBEC's contracts, the contracts provided that title to all tangible personal property passed directly from the vendor to the Government.
Id., at 724, 102 S.Ct., at 1377. "Finally, and most importantly, the contracts used a so-called 'advanced funding' procedure to meet contractor costs."
Id., at 725, 102 S.Ct., at 1378. The contractors paid creditors and employees with drafts drawn on a special bank account in which the Government deposited funds, so that only federal funds were expended when the contractors made purchases.
Id., at 726, 102 S.Ct., at 1378. Compare App. 142-143 (Declaration of Kenneth Meeks in Support of United States' Motion for Summary Judgment, describing similar funding operations with WBEC).

In New Mexico, the Government brought an action arguing that the contractors' expenditures, other than those made out of the fixed fees, were constitutionally immune from taxation. We noted that the doctrine of federal immunity from state taxation is "one that has been marked from the beginning by inconsistent decisions and excessively delicate distinctions."
455 U.S., at 730, 102 S.Ct., at 1380-1381. After surveying our "confusing" precedents, we concluded it was time to return to the underlying constitutional principle of tax immunity: A State may not lay a tax " 'directly upon the United States.' "
Id., at 733, 102 S.Ct., at 1382 (quoting Mayo v. United States,
319 U.S. 441, 447, 63 S.Ct. 1137, 1140, 87 L.Ed. 1504 (1943)). But whereas the Government is absolutely immune from direct taxes, it is not immune from taxes merely because they have an "effect" on it, or "even because the Federal Government shoulders the entire economic burden of the levy."
455 U.S., at 734, 102 S.Ct., at 1382. In fact, it is "constitutionally irrelevant that the United States reimburses all the contractor's expenditures, including those going to meet the tax." Ibid. (citing Alabama v. King & Boozer,
314 U.S. 1, 62 S.Ct. 43, 86 L.Ed. 3 (1941)). Tax immunity is "appropriate in only one circumstance: when the levy falls on the United States itself, or on an agency or instrumentality so closely connected to the Government that the two cannot realistically be viewed as separate entities."
455 U.S., at 735, 102 S.Ct., at 1383.

It is beyond peradventure that California did not taxindeed, could not have taxedthe Federal Government in this case. California taxed WBEC. And the Government's voluntary agreement to reimburse (or even fund in advance) WBEC for those taxes does not make the Government's payments direct disbursements of federal funds to the State. We addressed an analogous indemnification relationship in Brady v. Roosevelt Steamship Co.,
317 U.S. 575, 63 S.Ct. 425, 87 L.Ed. 471 (1943). The United States had contracted with a private corporation to operate a Maritime Commission vessel. A Customs Inspector suffered injuries on the vessel that led to his death, and his widow brought a maritime tort action against the private corporation. In defense, respondent contended "that if the judgment against it stands, the United States ultimately will have to pay it by reason of provisions of the contract between respondent and the Maritime Commission. It is therefore urged that the United States is the real party in interest."
Id., at 582, 63 S.Ct., at 429. We rejected respondent's argument that petitioner could be deprived of her cause of action by reason of the contract. "Immunity from suit on a cause of action which the law creates cannot be so readily obtained."
Id., at 583, 63 S.Ct., at 429. Absent congressional action, we would not allow "concessions made by contracting officers of the government" to make such a "basic alteration" in the law.
Id., at 584, 63 S.Ct., at 430.

We conclude from Brady and New Mexico that the Government cannot use the existence of an obligation to indemnify WBEC to create a federal cause of action for money had and received to recover state taxes paid by WBEC any more than the Roosevelt Steamship Company could use the existence of a right to indemnity from the Government to defeat a claim for recovery. See Brady,
supra, at 584, 63 S.Ct., at 430. Cf. Farid v. Smith, 850 F.2d 917, 923 (CA2 1988) (a State's decision to indemnify its public servants does not confer Eleventh Amendment immunity on state officials sued in their personal capacity).

Although the Government does not cite Brady, it does cite two other cases that suggest the lesson of Brady might not apply in an action for money had and received. According to the Government, Bayne v. United States,
93 U.S. 642, 23 L.Ed. 997 (1877), and Gaines v. Miller,
111 U.S. 395, 4 S.Ct. 426, 28 L.Ed. 466 (1884), stand for the proposition that an action for money had and received may "be employed by the United States to recover money from a third party who received federal funds that had been misappropriated by a government agent." Brief for United States 14. We find these cases inapposite. In Bayne, an Army paymaster withdrew money from the paymaster's account, endorsed the checks in blank, and sent them to Merchant's Bank with instructions to credit the account of Bayne & Co. The Court affirmed the Government's judgment against Bayne & Co. under an action for money had and received. 93 U.S., at 643. In Gaines, the agent of an estate's executors sold estate property and illegally kept a portion of the money.
111 U.S., at 396, 4 S.Ct., at 426. Many years later, the agent had died, but Gaines, the legatee of the first estate, brought an action in equity against the administrator of the agent's estate. The Court affirmed the lower court's judgment against Gaines because, among other reasons, she had an adequate remedy at law: an action for money had and received.
Id., at 397-398, 4 S.Ct., at 427.

Bayne and Gaines share two features this case lacks. The first is that, in each, the rightful owner of the money lost it by way of theft. That is, the money passed from the first party to the second party unlawfully. See Bayne, supra, 93 U.S., at 643; Gaines, supra,
111 U.S., at 396, 4 S.Ct., at 426. The second feature is that in both cases the rightful owner of the money sued a third party who had a relationship that, at least for our purposes, made that party legally responsible for the actions of the one who unlawfully took the money. The Court was satisfied in Bayne that the transactions between the paymaster, the banks, and Bayne & Co. were "the result of a fraudulent purpose to secure the use of the public money to Bayne & Co., who received it with full knowledge that it belonged to the United States, and had been applied in manifest violation of the act of Congress." 93 U.S., at 643. In other words, Bayne & Co. and the paymaster were accomplices, each liable for the acts of the other. Cf.
18 U.S.C. 2. In Gaines, petitioner sued the administrator of the agent's estate, who was legally responsible for paying the agent's debts out of the estate. See, e.g., 2 J. Perkins, Williams on Executors and Administrators 988-990 (6th Am. ed. 1877).

The Government does not contend that WBEC stole the money at issue in this case or otherwise took money from the Government unlawfully. WBEC did not. Nor does the Government contend that California and WBEC had a relationship that would make California liable for WBEC's actions. They did not. In fact, California and WBEC had an adverse relationship: that of creditor and debtor. California's demand that WBEC pay what California believed to be a lawful debt does not make California legally responsible for the Government's indemnification of WBEC. In these circumstances, we do not imply a contract in law between California and the Government. Without an implied contract, an action for money had and received will not lie against the State.

Although the Government cannot proceed in an action for money had and received, our discussion of indemnification suggests the Government may not be without recourse: Because it indemnified the contractor, the Government has a right to be subrogated to the contractor's claims against the State. See 10 W. Jaeger, Williston on Contracts § 1265 (3d ed. 1967); Brief for Respondents 13 (conceding the same). When proceeding by subrogation, the subrogee "stands in the place of one whose claim he has paid." United States v. Munsey Trust Co.,
332 U.S. 234, 242, 67 S.Ct. 1599, 1603, 91 L.Ed. 2022 (1947). Here WBEC's rights have lapsed and its claims are barred. Under traditional subrogation principles then, the claims of the United States also would be barred. The subrogee, who has all the rights of the subrogor, usually "cannot acquire by subrogation what another whose rights he claims did not have." Ibid. Although WBEC filed actions in state court within 90 days of the Board of Equalization's administrative decisions, WBEC later dismissed those cases without prejudice. A dismissal without prejudice terminates the action and "concludes the rights of the parties in that particular action." Gagnon Co. v. Nevada Desert Inn, 45 Cal.2d 448, 455, 289 P.2d 466, 472 (1955). A subrogee could have proceeded only if WBEC could have filed a new state-court action at that time, which it could not do.

"When the United States becomes entitled to a claim, acting in its governmental capacity, and asserts its claim in that right, it cannot be deemed to have abdicated its governmental authority so as to become subject to a state statute putting a time limit upon enforcement." Summerlin, supra,
310 U.S., at 417, 60 S.Ct., at 1020.

In contrast, the Government here became entitled to its claim by indemnifying a private contractor's state-law debt. It can assert its claim only by way of subrogation, an equitable action created by the courts. Summerlin is clearly distinguishable.

Whether in general a state-law action brought by the United States is subject to a federal or state statute of limitations is a difficult question. We need not resolve it today, however, because Guaranty Trust Co. v. United States,
304 U.S. 126, 58 S.Ct. 785, 82 L.Ed. 1224 (1938), provides guidance in this case. There the United States was proceeding as the assignee of the Soviet Government and sought to collect under state law. The petitioner argued that the statute of limitations had run, and the United States asserted, among other defenses, that it was not bound by state statutes of limitations. We found that the circumstances of the case "admitted of no appeal to such a policy."
Id., at 141, 58 S.Ct., at 793. Even if the United States had a right to be free from the statute of limitations, it was deprived of no right on those facts. "For the proof demonstrated that the United States never acquired a right free of a pre-existing infirmity, the running of limitations against its assignor, which public policy does not forbid."
Id., at 142, 58 S.Ct., at 793.

Here, although the Government acquired a right to subrogation to WBEC's claims upon payment of the taxes, the Government did not assert that right until it filed the federal judicial proceeding. As the California Supreme Court has held, " 'A surety by payment does not become ipso facto subrogated to the rights of the creditor, but only acquires a right to such subrogation, and . . . before the substitution or equitable assignment can actually take place he must actively assert his equitable right thereto. It is not a substantive tangible right of such nature and character that it can be seized and held and enjoyed independently of a judicial proceeding.' " Offer v. Superior Court of San Francisco, 194 Cal. 114, 117, 228 P. 11, 12 (1924) (quoting 25 Ruling Case Law 1391 (1929)). Accord, 10 W. Jaeger, Williston on Contracts § 1265, at 848, and n. 9 (citing cases). Because the Government waited until after the state statute of limitations had run against WBEC to bring suit, the Government was not subrogated to "a right free of a pre-existing infirmity." Guaranty Trust, supra,
304 U.S., at 142, 58 S.Ct., at 793. That the doctrine of subrogation is one of equity only strengthens our conclusion that the Government may not proceed: The Government waited ten years after the first notice of deficiency was issued, eight years after the second notice was issued, and almost six years after the state statute of limitations ran to bring this suit.

The Government argues that affirming the Court of Appeals often will leave it "without an effective remedy to contest a tax improperly exacted from a federal contractor" and subject it to the "vagaries" of 50 state tax-law procedures. Brief for United States 26-27. But federal contractors already are subject to the substantive tax laws of the 50 States. Nothing in our decision prevents the Government from including in its contracts a requirement that its contractors be responsible for all taxes the Government believes are wrongfully assessed, a contract term that likely would remove any disinterest a contractor may have toward litigating in state court. If our decision today results in an intolerable drain on the public fisc, Congress, which can take into account the concerns of the States as well as the Federal Government, is free to address the situation. See New Mexico,
455 U.S., at 737-738, 102 S.Ct., at 1384.

III

In United States v. New Mexico, we held that the Federal Government is immune only from state taxes imposed on it directly.
Id., at 734, 102 S.Ct., at 1382. In so holding, we hoped to "forestall, at least to a degree, some of the manipulation and wooden formalism that occasionally have marked tax litigationand that have no proper place in determining the allocation of power between coexisting sovereignties."
Id., at 737, 102 S.Ct., at 1384. Today we hold that shouldering the "entire economic burden of the levy,"
id., at 734, 102 S.Ct., at 1382, through indemnification does not give the Federal Government a federal common law cause of action for money had and received to challenge a state tax on state-law grounds simply because it is the Government. To do otherwise would be to return to the "manipulation and wooden formalism" we put aside in New Mexico.