What Does Box 12 Code W Mean on a W-2?
HSA contributions (employer + employee pre-tax through payroll). What it means, whether it is taxable, and what to do with it.
By the Easy Guides Editorial Team · Updated for 2026
Box 12 Code W is hsa contributions (employer + employee pre-tax through payroll).
What Code W means
If you also put money into the HSA outside of payroll, you may be able to deduct that extra amount on Form 8889, but not the Code W amount, which is already tax-free.
Does Code W affect my taxes?
The total contributed to your Health Savings Account through payroll, both your pre-tax contributions and any your employer added. It's already excluded from your Box 1 wages.
Where to find Code W on your W-2
Look at box 12, in the middle-right of the form. It has up to four lines, labelled 12a, 12b, 12c and 12d. Those letters are only line labels. The code you want is the small letter or pair of letters printed next to the amount, and it will read W. If you have more than four entries, your employer issues a second W-2 to carry the rest.
Not the code you were looking for? The full box 12 code list covers every letter, and the W-2 box decoder explains every box on the form.