HSA + Medicare: The Rules that Trip Up Late Enrollers
Once Medicare starts, HSA contributions stop. The lookback can claw back six months. Here are the rules that catch people who keep working past 65.
Health Savings Accounts (HSAs) and Medicare have a strict relationship. The IRS forbids HSA contributions while you are enrolled in any part of Medicare. The rule sounds simple but the timing creates several traps.
The basic rule
Once you enroll in any part of Medicare (including Part A only) you can no longer contribute to an HSA. You can still spend the existing balance on qualified medical expenses, including Medicare premiums and out-of-pocket costs. But new contributions stop the month Medicare coverage starts.
Automatic Part A enrollment
If you take Social Security at any age 65+, SSA automatically enrolls you in Part A. This is what catches most working-past-65 retirees off guard. They want to keep their employer HDHP and the HSA contribution that comes with it. Filing for Social Security ends both.
The six-month lookback
If you delay Medicare enrollment past age 65 and then enroll later, Medicare backdates your Part A coverage by six months (but not earlier than your 65th birthday month). So enrolling in May with a 65th birthday two years prior triggers Part A coverage starting November of the prior year. Any HSA contributions made during those six months become excess contributions, subject to 6% per-year excise tax until withdrawn.
Practical timing for late enrollment
If you plan to keep contributing to an HSA past 65, three rules: 1) Do not take Social Security. 2) Do not enroll in any Medicare part. 3) When you finally do enroll in Medicare, stop HSA contributions six months earlier than the enrollment date.
Spousal HSA still works
A spouse under 65 covered by a family HDHP can still contribute the full family limit ($9,300 in 2026) to their own HSA even after the older spouse enrolls in Medicare, as long as the under-65 spouse is the HSA account holder.
Using HSA for Medicare premiums
HSA dollars are perfect for Medicare premiums after 65. You can pay Part B, Part D, Medicare Advantage premiums, and IRMAA surcharges with HSA funds tax-free. Medigap is the one exception, HSA cannot be used for Medigap premiums. This is the cleanest IRMAA-aware drawdown for retirees with HSA balances.
HSA does not lower IRMAA-MAGI
Wait, but HSA contributions reduce AGI? Yes, but only when you are still working with payroll deductions, before Medicare. After 65 the HSA is more useful as a payment vehicle than as a MAGI tool. Plan accordingly.
The 1099-SA reconciliation
HSA distributions show up on Form 1099-SA. As long as you spend on qualified medical (which includes most Medicare costs except Medigap), the distribution is non-taxable and does not increase AGI. Keep receipts because the IRS audits HSA distributions sometimes.