HSA Retirement Calculator: Your Health Savings Account as a Stealth IRA
A health savings account is usually sold as a way to pay this year’s doctor bills. Used as an investment account instead, it can be the best retirement account you have: no tax going in, no tax on the growth, and no tax coming out for medical costs, which everyone has. Enter your plan, your contributions and your tax rates, and this calculator projects your HSA at retirement and compares it with putting the same paycheck dollars into a 401(k) or a taxable account.
Unlock this free calculator
Join my email list to use this tool and every other calculator on the site. You’ll also get plain-English tax and money tips, and a note when I add a new tool.
Free. One email list for every tool on the site; unsubscribe anytime. Already signed up on this browser? The tools unlock automatically.
Want your HSA working as hard as your 401(k)? Michael Jones, EA, CFP®, can fit your HSA into your retirement plan, pick where each dollar goes first, and plan withdrawals around Medicare and taxes.
Book a free 15-minute callHow the HSA compares
| HSA | Traditional 401(k) | Roth IRA | |
|---|---|---|---|
| Deductible going in | Yes | Yes | No |
| Skips Social Security and Medicare tax (payroll) | Yes | No | No |
| Tax-free growth | Yes | Tax-deferred | Yes |
| Tax-free withdrawals | For medical costs, any age | No | After 59½ and 5 years |
| Required minimum distributions | No | Yes | No |
Worked example
Dana is 41 and has self-only coverage with a high-deductible plan. She has $3,000 in it today, puts the 2026 maximum of $4,400 into her HSA through payroll and pays her $1,500 a year of medical bills out of pocket. In the 24% bracket, each year’s contribution saves her about $1,390 in income, Social Security and Medicare tax, so it costs her take-home pay only about $3,010. Invested at 6% with the $1,000 catch-up from 55, her HSA grows to about $249,000 by 65. Spent on medical costs, every dollar of that is tax-free. The same take-home dollars in a 401(k) would be worth about $176,000 after tax, and in a taxable account about $153,000. Along the way she banks about $36,000 of receipts she can reimburse herself for, tax-free, whenever she wants.
Planning the rest of your retirement money? The retirement withdrawal order calculator shows which account to spend first.
Frequently asked questions
What are the HSA contribution limits for 2026 and 2027?
For 2026, $4,400 with self-only high-deductible coverage and $8,750 with family coverage. For 2027, $4,500 and $9,000. If you're 55 or older, you can add $1,000 a year. Employer contributions count toward the limit.
Why use an HSA as a retirement account?
Contributions are deductible, growth is tax-free and withdrawals for medical costs are tax-free, at any age. Through payroll, contributions also skip Social Security and Medicare tax. No other account gets all of that, and everyone has medical costs in retirement.
What is the HSA receipts strategy?
Pay medical bills out of pocket now, keep the receipts and let the HSA stay invested. There's no deadline to reimburse yourself, so years later you can withdraw the total tax-free for any reason, as long as the expenses came after you opened the HSA.
What happens if I use HSA money for non-medical expenses?
Before 65, you pay income tax plus a 20% penalty. After 65, there's no penalty and the withdrawal is taxed like a traditional IRA, so the HSA is never worse than a traditional account for retirement.
Can I contribute to an HSA after 65?
Only if you have a qualifying high-deductible plan and aren't enrolled in any part of Medicare. Once Medicare starts, contributions stop, but you can keep spending and investing what's there.
Who should not invest their HSA?
If you need the money for this year's medical bills and don't have other savings, use it for that. Investing the HSA works best once you have an emergency fund and are already getting any 401(k) match.
Sources
- IRS Publication 969: Health savings accounts and other tax-favored health plans
- IRS: Rev. Proc. 2026-24 (2027 HSA limits)
- IRS: About Form 8889
- Medicare.gov: When coverage starts
Reviewed by Michael Jones, EA, CFP®, an Enrolled Agent federally licensed to represent taxpayers before the IRS. Projections use a steady return and today’s contribution limits, which rise with inflation. Past returns don’t guarantee future results. The comparison uses flat tax rates and doesn’t include employer 401(k) matches, which usually come first. This is education, not advice for your situation; book a free call for that.
