Enrollment

HSA Contributions After Medicare: The 6-Month Lookback

Written by Barley Billing Team, Medicare Billing Experts | Fact-checked against primary CMS sources | Last reviewed September 14, 2026

What This Means

A health savings account — an HSA — is the tax-free account many people pay into through work to cover medical costs. It comes with one hard condition: you can only put money in for months when you are not on Medicare. The IRS says it bluntly. From the first month you are enrolled in Medicare, the amount you are allowed to add is zero.

The trouble is that people find this out after Medicare has already started — and often after it started on a date in the past. Medicare Part A, the hospital half, can be backdated by up to six months. So money you paid in during, say, March can turn out to have gone in during a month when you were, on paper, already on Medicare.

Money paid in for those months is called an excess contribution, and the IRS charges a penalty tax of 6% on it. Not once. For every year it is still sitting in the account.

None of this is a punishment for doing something wrong. It is a problem about dates, and it has a fix.

Why This Happens

Two things combine, and neither is obvious.

Part A reaches backwards. When you apply for Medicare, Part A does not necessarily start on the day you asked for it. The regulation says an application filed within six months of your first month of eligibility is retroactive to that first month; an application filed later than that is retroactive to the sixth month before the month you filed. It never reaches back further than the month you first became eligible — so if you turned 65 in February and applied in March, there is no backdating to worry about at all.

Claiming Social Security switches Part A on by itself. If you start taking Social Security at or after 65, you are enrolled in Part A automatically. You do not apply for it, you are not asked, and nothing in the Social Security paperwork mentions your health savings account. Plenty of people discover the connection a year later, from their tax preparer.

Put together: you claim Social Security in September, Part A is backdated to March, and the six monthly contributions you made between March and September were all excess.

The Part Nobody Tells You: You Probably Cannot Undo the Part A

Read around this subject and you will find the six-month rule and the 6% tax stated correctly nearly everywhere. What is almost never mentioned is the thing most readers try next — turning Part A off.

If you are drawing Social Security, you cannot. Social Security’s own operating rules say it outright: people entitled to monthly benefits that confer eligibility for hospital insurance “may not waive HI entitlement.” The only route out is to withdraw your Social Security application altogether — and withdrawal “requires repayment of all RSDI and HI benefit payments made.” Every Social Security payment back, and everything Medicare has paid on your behalf back.

For nearly everyone that is a far worse outcome than the tax. And for most readers of this page it is not even on the table: Social Security accepts a withdrawal of a retirement application only if you file it within 12 months of your first month of entitlement, and only once in your lifetime. If you have been drawing benefits for more than a year — and if you are finding this out from a tax preparer, you probably have — there is no route out of Part A at all.

It is worth knowing early, because the instinct to “just cancel Part A and put the money back” is strong and it leads nowhere. Even where dropping Part A is possible it works forwards, not backwards: it would stop future months counting, and would do nothing about the contributions already made.

So the fix is on the HSA side, not the Medicare side.

What To Do Next

  1. Find the real start date of your Part A. It is on your Medicare card and in your Medicare account at medicare.gov. Do not assume it is the date you applied.

  2. Count the months. Every month from that start date onwards is a month you were not allowed to contribute. Your allowance for that year is cut down to match: take the full year’s maximum, divide it by twelve, and multiply by the number of months before Medicare started. That is all you were entitled to put in. Add up what actually went in for the months after — including anything your employer put in, which counts exactly as your own money does.

    One case is worse than this, so check it. If you used the “last-month rule” to put in a full year’s contribution on the strength of being covered on December 1, you also agreed to stay eligible through the following year — the testing period. Going onto Medicare breaks that, and the failed portion is taxed as income with an additional 10% tax on top, which is a different and larger problem than the 6% excise. If any of that sounds like you, take it to a tax preparer rather than working it out from this page.

  3. Take the excess out, and take the earnings with it. This is the part that cancels the tax. The IRS will not charge the 6% on an amount you withdraw before the due date of your tax return for the year the contributions were made, including extensions — but only if you also withdraw the income those contributions earned and report that income. Ask your HSA provider for a “return of excess contribution.” It is a specific form and they do it routinely; a plain withdrawal will not work.

  4. If the year has already closed, do it anyway. The 6% applies for each year the excess is still in the account at year end, so taking it out now stops the clock even though you cannot undo the years already gone. Form 5329 is where excess contributions and the tax are reported.

  5. Stop the payroll deduction today if you are still working. This is the single most common way the problem quietly doubles.

  6. Get the tax part checked by a person. This page explains the rule; it is not tax advice, and the numbers depend on your own filing position. A tax preparer will do that sum in ten minutes.

  7. Then go back to using the account. Nothing here stops you spending it. Once you are 65 the HSA can pay your Part B, Part D and Medicare Advantage premiums, which for most people is the largest recurring medical bill they now have.

Sources

Frequently Asked Questions

Can I still use the money already in my HSA?
Yes, and this is a different question from contributing. Medicare stops you putting money in. It does not touch the money already there. You can spend it on qualified medical expenses for the rest of your life, and once you are 65 that includes your Medicare premiums — Part B, Part D and Medicare Advantage, though not Medigap premiums.
How far back does Part A actually go?
If you applied within six months of first becoming eligible, Part A starts at that first month of eligibility. If you applied later than that, it starts six months before the month you applied. It never starts before you were eligible, so someone who applies at 65 and a month is not backdated to 64.
Does the 6% tax happen once?
No. It applies for each year the excess is still sitting in the account on the last day of the year. Leave it for three years and you have paid it three times.
My employer put money in, not me. Does that count?
Yes. Employer contributions count towards your limit exactly as your own do, and they become excess the same way. This catches people who stayed on at work and never changed the payroll setting.
Can I just turn Part A off?
Usually not, and even when you can it does not fix the past — dropping Part A stops future months, it does not unwind months already elapsed, so the contributions already made stay excess. If you are drawing Social Security you cannot give up Part A on its own at all: the only route is withdrawing your Social Security application and repaying every payment you have received, Social Security and Medicare both. And that route is itself closed to most people — Social Security accepts a withdrawal only within 12 months of your first month of entitlement, and only once in a lifetime. The fix is on the HSA side.

This information is for educational purposes only and is not legal or medical advice. Always verify with your doctor's office and insurance company.