One of the biggest complaints about Social Security is that a portion of one's benefits must be given back to the government by way of income taxes. But while the federal government provides few safe harbors from this circular process, more than two dozen states have decided to exempt Social Security benefits from state income taxation altogether.

Social Security and federal taxes
To be fair, the taxation of Social Security at the federal level gets somewhat of a bad rap. This is because the potential tax liability is limited in both size and scope.

In the first case, you don't pay taxes on your benefits if they're your only source of income. Taxes only kick in if your "combined income" -- which equals your adjusted gross income plus your nontaxable interest plus half of your Social Security benefits -- exceeds certain thresholds.

Additionally, even if your combined income falls within the taxable range, no more than 85% of your benefits will be used to calculate your tax liability. I know this is little consolation, but it nevertheless leaves the remaining 15% of your benefits free and clear.

The net result is that, assuming an individual's combined income exceeds $34,000 ($44,000 for married couples), as much as 85% of it will be taxed as ordinary income.

Social Security and state taxes
The situation on the state level isn't quite as clear-cut. This is because various states treat Social Security benefits differently for the purposes of income taxes.

You can see this in the chart below, which breaks down the number of states that tax Social Security in one of four ways.

As you can see, 27 states have elected to completely exempt Social Security payments, according to data from the Tax Foundation. This includes Oregon, California, Idaho, Arizona, Oklahoma, Arkansas, and Louisiana, among others.

Meanwhile, eight states exempt Social Security from income taxes subject to specific factors. For instance, Missouri allows married taxpayers with adjusted gross income of less than $100,000 to deduct all taxable Social Security benefits from income. And nine states have no state income tax altogether.

The remaining six states tax benefits to the same extent they're taxed at the federal level.

Like I intimated above, this is no consolation to someone who relies on Social Security for retirement, but must still remit a portion of it to the government. But it's nevertheless better to know the law than to face an audit from the IRS.