You may have an unsung hero lurking in the wings of your retirement plan. It's your HSA, or health savings account, and it could save you from getting buried under healthcare bills in your golden years.

HSAs, available only to individuals who are covered by a high-deductible health plan (HDHP), are tax-advantaged accounts designed to help you manage healthcare costs. A qualifying HDHP has a minimum deductible of $1,400 for individuals and $2,800 for families.

An older couple laughing on a bench in the park

Image source: Getty Images.

HSAs: What to know

An HSA is operationally similar to a 401(k). If you set one up through your employer, your HSA contributions are made with pre-tax dollars from your paycheck. If you open an account that's not tied to your employer, then you'd get tax deductions on your HSA contributions. You can then withdraw the funds without tax implications to cover qualified healthcare expenses. Premiums don't count unless you're over 65 years old, but co-payments, deductibles, and co-insurance do qualify.

Here's the fun part. You can invest your HSA balance in mutual funds, and the earnings grow tax-free. That's three total tax benefits in one account: contributions are tax-free, earnings grow tax-free, and withdrawals for qualified expenses are tax-free. And, unlike a flexible spending account, or FSA, your HSA balance rolls over from year to year, so it never expires.

Once you reach 65, things get really interesting. At that point, you can use HSA funds to pay your healthcare premiums tax-free. And if you want to use your funds for something other than healthcare, you can without penalty -- you simply pay income tax on that distribution, as you would for a 401(k) withdrawal. That means the risk of over-contributing to your HSA is low, as long as you won't need the funds for non-qualified expenses before age 65. If you think you might, it's better to put those funds in your 401(k), since you can take penalty-free, taxable distributions out of that account at age 59 1/2.

As with other tax-advantaged retirement plans, the HSA does have contribution limits mandated by the Internal Revenue Service. The maximum HSA contribution allowed in 2020 is $3,550 for individuals and $7,100 for families. If you are over 55, you can also make $1,000 in HSA catch-up contributions.

A case for maximum HSA contributions

Now, let's tackle the question of how much you should contribute to that HSA. One strategy is to use the account for your current-year medical expenses. That would involve estimating your annual, out-of-pocket healthcare costs and then aligning your contributions with that total. Data from the Employee Benefit Research Institute (EBRI) suggests this is a common approach. EBRI found that about 75% of HSAs with a contribution in 2018 also had a distribution in the same year. In the same study, EBRI concluded only 14% of HSA accountholders maxed out their contributions.

Alternatively, you could take a longer-term view and use your HSA to save for retirement. In that case, you'd want to start maxing out those HSA contributions immediately. You might even decide to pay your current medical expenses outside of the HSA in order to maximize what you'll have available in retirement. Here are four reasons that makes sense.

  1. Healthcare costs after you retire will be higher than you think. Health View Services predicts that healthcare costs will outpace general inflation, rising by 4.22% annually. The report also concludes an average 65-year-old couple retiring in 2019 will face $363,946 in future healthcare premiums and out-of-pocket costs.
  2. Once you enroll in Medicare at 65, you are no longer eligible to contribute to your HSA. If you reduce or deplete your HSA funds each year while you are working, your account will eventually run dry in retirement. But in retirement, you're on a fixed income. And that's when you'll most appreciate having tax-free funds set aside for healthcare.
  3. You can take advantage of compound earnings by investing your HSA contributions and holding those investments for 10 or 20 years. The most reliable way to amass a large sum of money is to invest over the long term. You can use your HSA to make that happen.
  4. You can use the HSA funds for living expenses and healthcare premiums after you turn 65. Once you turn 65, you can pay your Medicare premiums with HSA funds. You can also take distributions for living expenses, as long as you pay income tax on those amounts. For that reason, there's little risk of contributing too much to your HSA.

How much you can save

Say you're targeting an HSA balance of $364,000 to cover those predicted family healthcare costs. To get there, you'd have to make the maximum allowed HSA family contribution of $7,100 annually and invest it to earn 7% on average. You'll hit the $364,000 target in just under 22 years.

In that same period of time, maximum annual individual contributions of $3,500 invested at 7% would grow to about $183,000. If you only have 10 years before retirement, your maxed-out contributions would grow to about $103,000 for families and $51,000 for individuals, again assuming 7% growth. In a five-year span, you can accumulate $42,000 with the family contribution and $21,000 with the individual contribution.

These calculations are not set in stone, of course. Contribution limits will go up in future years, and you'll eventually qualify for catch-up contributions, which will help you save faster. The point is, max out the HSA contribution if you can. And don't overlook the benefits of opening an HSA if you're eligible for one. Saving diligently in an HSA gives you a head start on future healthcare costs with relatively little downside.