Yesterday's Supreme Court decision in United States v. Windsor was momentous, establishing that the federal government can't treat opposite-sex and same-sex marriages differently, and must recognize the tens of thousands of legally married gay, lesbian, and bisexual couples in the U.S. But as Neil noted, it was also, ultimately, about a tax bill.

The reason Edie Windsor could challenge the Defense of Marriage Act is that it denied her the spousal exemption to the estate tax. Since 1981, there's been an unlimited exemption in the estate tax for money and assets left to spouses. If the federal government had treated Ms. Windsor and her wife, Thea Spyer, as a married couple, she would have owed no estate tax for what money and assets Spyer left her. But because she was not considered Spyer's spouse, she owed the federal government $363,053. The Supreme Court's ruling obviates that claim against Ms. Windsor, returning the money to her.

The decision, and subsequent rulemaking by the IRS, will almost certainly mean that gay and straight couples will be treated equally by the tax code. But Ms. Windsor's tax situation reminds us that the tax code, and the federal government in general, still discriminates in a more fundamental away: against single people, and in favor of the married.

The estate tax exemption is perhaps the most egregious example of this. The exemption Ms. Windsor is now claiming would not be available if she and Ms. Spyer had chosen, for whatever reason, to remain unmarried. It would not be available if Ms. Spyer had not found a wife, and left the money to a friend or relative instead.

But all manner of other policies are biased against single people. Social Security, for instance, includes a spousal benefit worth half of the benefit a worker receives. Spouses can receive the benefit even if they've never worked themselves, and even if they're divorced (provided the marriage lasted at least 10 years). But if they did work themselves, and worked enough to get a benefit larger than the spousal benefit, they don't get it. Effectively, the spousal benefit serves to advantage 1950s-style marriages, with one breadwinner and another stay-at-home spouse, and disadvantage two-earner households, not to mention unmarried couples and single people.

Even the federal income tax, which is often alleged to have a "marriage penalty," is biased in this manner. It's absolutely true that there are some couples who pay less in taxes if unmarried than they would if married.

Suppose, for example, Mary and Jill are married, and each make $250,000 (I'm choosing a high number for simplicity, but this applies to some people making less than this too). If they filed jointly, their income would be $500,000, in excess of the $450,000 cutoff for the top 39.6 percent tax bracket for married couples filing jointly. If they were single, each would fall into the 33 percent tax bracket, and likely pay a lot less overall. They could be married and file separately, but because the cutoff for the top bracket for people in that situation is $225,000 (half the married-filing-jointly cutoff, and way below the $400,000 cutoff for single people) they wouldn't save much, if anything. They're better-off being single.

But as this 1997 CBO paper from Roberton Williams and David Weiner (an oldie, but a goodie!) shows, some couples benefit for joint filing. Suppose instead that Mary alone works, and makes $425,000 a year, while Jill stays at home. If they each filed individually, Mary would easily top the $400,000 cutoff for the top bracket. But because the cutoff is $450,000 for couples, she pays a top rate of 36 percent instead. The income tax code, effectively, benefits single-earner married couples at the expense of dual-earner ones.

And because there are more of the former than the latter, there's a net "marriage bonus," or at least there was when Williams and Weiner wrote (which, sadly, is the most recent CBO data available); 51 percent of taxpayers got a bonus, compared to 42 percent who got a penalty, with a net $4 billion bonus overall. Williams says that some changes to the tax code since 1997, such as the introduction of the 10 percent tax bracket, should reduce penalties on the low end and increase the overall bonus rate. Then again, more families today are dual-earner rather than single-earner, which works in the opposite direction.

This Tax Foundation chart illustrates the point well:

And this Tax Policy Center calculator lets you see how different couples' penalties and bonuses vary. As the Tax Foundation chart shows, this issue is particularly pressing for equal-earners on the low and high ends of the income spectrum. In particular, the Earned Income Tax Credit can often result in a big marriage penalty for low-income people, as Eugene Steuerle points out here.

That's a problem, because that's the part of the population whose marriage decisions are elastic -- that is, they respond to changes in incentives like that. "If you ask, 'Where is marriage elastic, where is it highly variable, where are people finding it more acceptable to not get married?', it's in the bottom 60 percent," says Anne Alstott, an expert in taxation and social welfare policy at Yale Law School. By contrast, she says, college grads and graduate school grads are likelier to marry and stay marry regardless of what it means for them financially.

In an upcoming paper in Tax Law Review, Alstott argues that, regardless of what you want the tax code to do on marriage, it's probably ill-suited for the task. That's obviously true for those concerned about discriminating against single people or people in non-marriage household arrangements, but it holds even if you're a social conservative who wants to promote marriage. "Marriage bonuses are like throwing dollar bills out of a helicopter," Alstott says. "They may or may not hit the right people."

What would be better, she argues, is to identify where you want to promote marriage and design tax incentives that will sway those people. For example, if you want to reduce the rate of "multiple partner fertility" (that is, having children with a number of different sexual partners rather than one long-term partner), then give a tax credit to couples who stay together to raise their children. You could even tax the marriages of high earners, who tend to get married regardless and yet get a "marriage bump" in earnings. "Both liberal and welfarist ideals might support the use of marriage as a 'tag' for class privilege or ability (respectively) in order to redistribute income fairly and with less deadweight loss," Alstott writes. In plain English, that means taxing marriage for high-earners could be a way to taxing privilege without hurting the economy.

All of that, Alstott argues, ought to be tacked onto a system wherein everyone pays their own taxes. No joint-filing, or "married filing separately" status, and no "head of household" status for single parents. Just one income tax schedule for everyone. This isn't unprecedented. As Williams and Weiner's history notes, it was how the income tax worked up until 1948.

And it's easier to enforce than you might think. The 1948 change occurred in part because of the risk of income-shifting, or of a spouse transferring money to their partner as a way of reducing their tax liability. But the vast majority of people only make wage income, which is easy to assign to one person. The real problem occurs with capital income. "This is a problem for taxing rich people," Alstott explains. And better technology means we're now able to track capital income well too. "It's easier to do now than it was in the age of bearer bonds," Alstott says. "Say a guy who hasn't worked in 15 years suddenly has 150,000 dollars in the bank account. That's not really plausible is it?" We could also do what Canada does and ignore transfers between spouses for tax purposes.

And, critically, eliminating joint filing and the head-of-household status would put all household types on an even playing field for the purposes of taxation. Couples who for whatever reason choose to stay unmarried would be treated equally, as would single people. If you believe, as the single-rights activist Bella DePaulo does, that "singlism" is a major problem, that would be a major change for the better.