How to Use Your HSA as a Stealth Retirement Account.
The HSA is the only account in the tax code with a triple tax break: deductible going in, tax-free growth, and tax-free withdrawals for medical costs. Fund it, invest it, leave it alone, and after 65 it works like a traditional IRA with a medical superpower.
A software engineer with a high-deductible health plan treats the health savings account his employer offers as a checking account for copays, spends it down every year, and never thinks about it again. He is wasting the best tax shelter available to him. Used as a retirement account instead of a spending account, an HSA is the only vehicle in the code that is tax-free at all three stages: deductible going in, tax-free while it grows, and tax-free coming out for medical costs. For the right saver, an HSA works better than a 401(k) or a Roth, dollar for dollar.
Why the HSA beats a 401(k) as a retirement account.
A traditional 401(k) is taxed on the way out. A Roth is taxed on the way in. The HSA, under IRC §223, is taxed at neither stage, as long as the money eventually pays for a qualified medical expense. Contributions are an above-the-line deduction on Schedule 1 through Form 8889, so they cut your adjusted gross income whether or not you itemize. The balance grows tax-free. And qualified medical withdrawals are tax-free with no time limit. If you fund it through payroll under a cafeteria plan, you also skip the 7.65% Social Security and Medicare tax, which no other retirement account lets you do. That is closer to a quadruple break than a triple one. And unlike a flexible spending account, the money never expires at year-end and the balance stays yours when you change jobs or health plans.
Don't spend it. Invest it and save the receipts.
The move that turns an HSA into a retirement account is counterintuitive: do not reimburse yourself now. Pay this year's medical bills from your regular cash, invest the HSA in the same funds you would use in a brokerage account, and let it compound for decades. The IRS sets no deadline to reimburse yourself for a qualified expense, so every medical receipt you keep, from a $40 copay to a $6,000 procedure, becomes a coupon for a future tax-free withdrawal. Save the receipts, and years later you can pull that money out tax-free against expenses you paid long ago. Max the family limit at $8,750 a year, earn 7% on it, and after 30 years the account holds roughly $825,000, none of it taxed if it goes to medical costs.
It turns into a traditional IRA with a bonus.
The rule that removes the risk is what happens at 65. Before 65, a withdrawal for something other than a medical expense is taxed as income and hit with a 20% penalty. At 65, the penalty disappears. A non-medical withdrawal is simply taxed as ordinary income, exactly like a traditional IRA distribution under §223(f)(4). So the worst case for an over-funded HSA is that it behaves like a traditional IRA, and the best case is that it stays tax-free for medical costs, which almost everyone has in retirement. Medicare premiums for Part B and Part D even count as qualified expenses, though a Medigap policy does not. And unlike a traditional IRA, an HSA has no required minimum distributions, so it can keep compounding untouched.
- 2026 family HSA contribution limit
- $8,750
- Federal income tax saved at 22%
- $1,925
- Social Security and Medicare saved via payroll (7.65%)
- $669
- State income tax saved at 5% (illustrative)
- $438
- First-year tax reduction on the contribution
- $3,032
- Balance after 30 years at 7%, funded at $8,750 a year
- ~$825,000
Tax year 2026; the $8,750 family limit is from Rev. Proc. 2025-19. The 7.65% payroll tax saving assumes contributions run through a §125 cafeteria plan and that wages are below the Social Security wage base; above it, only the 1.45% Medicare portion is saved, and direct contributions not run through payroll get the income-tax deduction but no payroll-tax saving. The 22% federal bracket, 5% state rate, and 7% return are illustrative. The 30-year figure is a level $8,750 annual contribution growing at 7%.
Who can contribute, and the Medicare trap.
The HSA only works if you are eligible to fund it. You need a qualifying high-deductible health plan (for 2026, a minimum deductible of $1,700 for self-only or $3,400 for family coverage), you cannot be enrolled in Medicare, and you cannot be claimed as someone's dependent. The trap catches people near 65: enrolling in Medicare, or claiming Social Security after 65, which back-dates Medicare Part A up to six months, ends your eligibility. Contribute during that lookback window and you create an excess contribution subject to a 6% excise tax. If you plan to work past 65 and keep contributing, stop HSA contributions at least six months before you enroll in Medicare or file for Social Security. Coordinating an HSA with the rest of the plan is the same year-end conversation as the mega backdoor Roth.