Millions of Americans rely on their Social Security benefits to cover some or all of their living costs in retirement. And while the program has been a fixture of American life since 1935, in recent years, there's been talk that Social Security was going bankrupt -- and going away.

In fact, in a 2016 Transamerica survey, 77% of workers expressed concern that Social Security is in danger of completely running out of money by the time they're ready to retire. But while it's true that the program is set to encounter some funding problems in the not-so-distant future, it's not facing complete insolvency. If you're worried about Social Security going bankrupt, here's a quick fact check that will help you separate myth from reality.

Senior man looking out the window

IMAGE SOURCE: GETTY IMAGES.

Is Social Security running out of money?

In order to see why so many people think that Social Security is in danger, we first need to understand how the program works. Social Security is a pay-as-you-go system. Current workers are taxed on their earnings up to a certain dollar amount, which can change from year to year. In 2017, for example, workers will pay Social Security taxes on their first $127,200 of earnings. This tax revenue is then used to fund payments to current beneficiaries. Whatever is left over is "deposited" into a Trust Fund. (More on that later.)

Thus, when you pay into Social Security, you're not funding your own personal retirement account. Rather, the taxes you pay are pooled with the rest so that today's recipients can collect benefits. When it's your turn to retire, future workers' taxes will be used to fund your benefit payments.

The problem, however, is that in recent years, more Americans have been retiring from the workforce than entering it. Furthermore, Americans' life expectancies have been increasing, which means that those who are getting benefits will probably collect them for longer. The result? The amount of incoming Social Security tax revenue won't suffice to cover outgoing benefit payments. In fact, it's estimated that by 2034, the ratio of workers paying taxes to support Social Security beneficiaries will decline from 3:1 to 2:1.

Social Security's trust funds: an interim fix

For many years, there was more money coming into Social Security than there was going out, and thus the program's Trust Funds were born. These serve a key purpose: When incoming tax revenue isn't enough to fully cover benefits, the Trust Funds can be tapped to bridge the gap.

The problem, however, is that since 2010, Social Security has been paying out more money than it's been collecting via taxes, and starting in 2019, Social Security will start relying on its Trust Funds to keep up with benefits. But the Trust Funds only have so much money, and come 2034, unless Congress acts to change matters, they're likely to be completely depleted. Once that happens, an estimated 88 million Social Security recipients could face as much as a 21% reduction in benefits. For the average retiree, that equates to roughly $5,360 of lost benefits annually in today's dollars. Ouch.

What this means for you

If you're already receiving Social Security benefits, here's some good news: You shouldn't have to worry about that reduction for a good 17 years. But if you're a current worker worried about the future of Social Security, there's a solid basis for concern. After all, a 21% benefits cut could be catastrophic for low-income recipients who rely on Social Security to provide the bulk of their retirement income.

At the same time, let's keep things in perspective. Social Security isn't going away. Even in the worst-case scenario, under which lawmakers do nothing to increase its revenues or otherwise trim its outlays, the program is expected to have sufficient income to cover its benefit payments at 79% of previous levels. Furthermore, we don't what sort of legislation might be approved to get the program's numbers back in balance.

But here's one thing we do know: Social Security was never designed to support retirees financially on its own. The Social Security Administration itself states that benefits will replace about 40% of the average worker's pre-retirement income. Most people need more than that to survive once they're no longer working. Even if you plan to lead a fairly modest lifestyle in retirement, there's a good chance you'll still need a good 70% of your former income to keep up with your bills. And if you're hoping to travel or keep busy, you might need 80%, 90%, or more.

That's why it's crucial to save independently and not rely solely on Social Security to pay your bills in retirement. Even without a reduction in benefits, most retirees will still face a personal budget shortfall if they are expecting to bank on Social Security alone. Current workers under 50 can contribute up to $5,500 a year to an IRA and $18,000 a year to a 401(k), and those limits increase to $6,500 and $24,000, respectively, for workers 50 and older. Saving for retirement with these tax-advantaged accounts can help you grow relatively small contributions into a larger sum over time, and the longer you have to invest, and let your investments grow, the more sizable a nest egg you're likely to amass.

For example, a series of $200-a-month contributions will grow into almost $227,000 over 30 years if your investments generate an average annual 7% return, which is below the stock market's average. Increase that monthly contribution to $400, and you'll be looking at $453,000 in 30 years' time.

Social Security is indeed here to stay, but rather than worrying about its future, you're far better off focusing your energy on setting aside money and making smart investment choices. This way, that government benefit will serve as more of a bonus and less of a lifeline when it's your turn to collect it.