RetirementForge

2026 HSA Calculator

See what a Health Savings Account is actually worth at retirement compared with a 401(k) or a taxable account — then find the last month you can legally contribute before Medicare shuts the door, including the six-month Part A lookback that turns careful savers into excess-contribution penalties.

45
1864
65
4665
$4,400
$0$9,750
$10,000
$0$250K
$90,000
$20K$400K
7%
0%12%
22%
0%37%

Your HSA at age 65

$219,077

every dollar of it tax-free for qualified medical expenses · 20 years of growth

HSA

Balance$219,077
Tax to use itNone
Spendable$219,077

Traditional 401(k)

Balance$219,077
Tax to use it−$48,197
Spendable$170,880

Taxable brokerage

Balance$157,081
Tax to use it−$13,106
Spendable$143,975

Spent on health care, the HSA is worth $48,197 more than the same money in a traditional 401(k) — purely because the withdrawal is never taxed.

Contributing through payroll also avoids $337 of FICA a year (7.65%), about $6,732 over 20 years.

For educational purposes only; not tax advice. Nominal figures, no inflation adjustment. The taxable column grows at the full return rate and is taxed once on the whole gain at 15% — real taxable accounts also lose tax on dividends and turnover each year, so the HSA's true advantage is at least what is shown. The 0.9% Additional Medicare Tax is not modelled. Assumes contributions run through an employer §125 cafeteria plan, the only route that avoids FICA. HSA contributions must stop at Medicare enrollment — see the Medicare cutoff mode.

Plan this with an advisor

RetirementForge models HSA funding, Medicare timing, and the tax impact in a live client session.

Start free

Frequently Asked Questions

What are the 2026 HSA contribution limits?
For 2026 the annual limit is $4,400 for self-only high-deductible health plan coverage and $8,750 for family coverage, set by IRS Revenue Procedure 2025-19. If you are age 55 or older by the end of the year you can add a $1,000 catch-up contribution. The catch-up is per person, so a married couple who both want it must each have an HSA in their own name, even under a single family plan.
When do I have to stop contributing to my HSA before Medicare?
Enrollment in any part of Medicare, including premium-free Part A, ends your eligibility to contribute. If you enroll after age 65, Part A is generally backdated up to six months, though never earlier than the month you turned 65, and contributions made during that retroactive window become excess contributions. The standard guidance is to stop HSA contributions at least six full months before you enroll in Medicare or claim Social Security. This calculator computes the exact month for your situation.
How is my HSA limit prorated if I am only eligible part of the year?
The IRS does not simply divide the annual limit by the months you were covered. Under the Form 8889 Line 3 method your limit is the greater of two figures: the month-by-month total, counting each month you were an eligible individual on the first day of that month, or the full annual amount under the last-month rule if you were still eligible on December 1. Taking the greater of the two often produces a larger limit than straight proration.
What is the penalty for contributing too much to an HSA?
An excess contribution is subject to a 6 percent excise tax for each year it remains in the account, and the excess is generally included in income. This is a separate penalty from the last-month rule testing period. If you relied on the last-month rule to contribute a full year and then stopped being eligible during the testing period, the contributions allowed only because of that rule are included in income plus a 10 percent additional tax. The two penalties have different triggers and can both apply.
Does an HSA really save more tax than a 401(k)?
For money spent on qualified medical expenses, yes. Both accounts are funded with pre-tax dollars and grow without annual tax, but a traditional 401(k) withdrawal is ordinary income while a qualified HSA withdrawal is never taxed. HSA contributions made by payroll deduction through an employer cafeteria plan also avoid Social Security and Medicare payroll taxes, which no 401(k), IRA, or Roth contribution does. That payroll break is 7.65 percent for most earners, but only the uncapped 1.45 percent Medicare portion on wages above the Social Security wage base.
Can I use HSA money to pay Medicare premiums?
Yes for Medicare Part B, Part D, and Medicare Advantage Part C premiums, which are qualified medical expenses payable tax-free. Medigap, also called Medicare Supplement insurance, is not a qualified expense, so paying a Medigap premium from an HSA produces a taxable withdrawal, though after age 65 it would not carry the additional 20 percent penalty.