Box 12 on Form W-2 is one of the most misunderstood parts of the form, but those letter codes and dollar amounts are not random. They identify specific benefits, contributions, and tax situations that can affect how you complete your return. This quick guide explains what Box 12 is, how to read it, and what the most common codes mean so you can file with confidence.
If you need a broader refresher on wage reporting, see BoomTax’s guide to W-2 forms. For official guidance, the IRS also provides resources about Form W-2 and in the current Instructions for Forms W-2 and W-3.
What Is Box 12 on Form W-2?
Box 12 contains one or more letter codes paired with dollar amounts. Each code points to a specific type of pay, benefit, or tax situation.
You may see multiple entries, such as 12a, 12b, 12c, and 12d, because more than one item can apply to you. If there is nothing to report, Box 12 can be blank.
In many cases, the amount shown in Box 12 is not additional taxable income. It is often informational. However, some entries do affect your return, such as health savings account (HSA) contributions or adoption benefits. Understanding the Box 12 codes helps you enter the right information into your tax software and avoid mistakes.
How Box 12 Affects Your Taxes
- Some codes are purely informational and do not change your taxable income, such as Code DD for the cost of employer-sponsored health coverage.
- Retirement plan deferrals, such as 401(k) contributions under Code D, generally reduce your federal taxable wages in Box 1, but not your Social Security and Medicare wages in Boxes 3 and 5.
- Designated Roth contributions under Codes AA, BB, and EE are after-tax. They are included in Box 1 income and are also subject to Social Security and Medicare taxes.
- HSA and Archer MSA contributions under Codes W and R often require an additional form when you file your tax return, such as Form 8889 for HSAs or Form 8853 for Archer MSAs.
- Some codes indicate uncollected Social Security or Medicare tax, including Codes A, B, M, and N. You may owe these amounts when you file.
When in doubt, match the Box 12 code to the IRS instructions for Form W-2 and follow your tax software prompts carefully. Employers and payroll teams should also review the IRS guidance each year, including Publication 15-A where applicable for employer tax treatment questions.
Common Box 12 Categories and What They Mean
Here are the categories you are most likely to see, with examples of codes in each. This is not a complete list, but it covers many common situations for employees.
Retirement plan contributions
- D: 401(k) elective deferrals
- E: 403(b) elective deferrals
- F: 408(k)(6) SEP (SARSEP) elective deferrals
- G: 457(b) elective deferrals and employer contributions
- H: 501(c)(18)(D) plan contributions
- S: SIMPLE IRA (408(p)) salary reduction contributions
- AA: Designated Roth contributions to a 401(k)
- BB: Designated Roth contributions to a 403(b)
- EE: Designated Roth contributions to a governmental 457(b)
Pre-tax deferrals under D, E, F, G, H, and S generally lower Box 1 wages. Designated Roth contributions under AA, BB, and EE do not.
Health and welfare benefits
- W: Employer contributions to an HSA, including employee contributions made through payroll under a cafeteria plan. Often requires Form 8889.
- R: Employer contributions to an Archer MSA. Often requires Form 8853.
- DD: Cost of employer-sponsored health coverage. Informational only and not taxable.
- FF: Permitted benefit amount under a QSEHRA, or Qualified Small Employer Health Reimbursement Arrangement.
Insurance, stock, and special compensation
- C: Taxable cost of group-term life insurance over $50,000. This is already included in wages where applicable.
- V: Income from exercise of nonstatutory stock options. This is included in Box 1 wages.
- GG: Income from qualified equity grants under section 83(i).
- HH: Aggregate deferrals under section 83(i) elections as of year-end.
- T: Adoption benefits provided by your employer. May require Form 8839.
- P: Excludable moving expense reimbursements paid directly to a member of the U.S. Armed Forces, subject to specific rules.
- Q: Nontaxable combat pay.
Uncollected Social Security and Medicare tax
- A: Uncollected Social Security or RRTA tax on tips.
- B: Uncollected Medicare tax on tips.
- M: Uncollected Social Security or RRTA tax on taxable cost of group-term life insurance for former employees.
- N: Uncollected Medicare tax on taxable cost of group-term life insurance for former employees.
Nonqualified deferred compensation (NQDC)
- Y: Deferrals under a section 409A NQDC plan. Informational only.
- Z: Income under section 409A due to plan failure. This is generally taxable and may carry an additional tax.
Other less-common items
- J: Nontaxable sick pay paid by a third party, usually an insurer.
- K: 20% excise tax on excess golden parachute payments, withheld.
Real-World Examples
- Example 1: 401(k) deferral (Code D) — Your W-2 shows Box 12 Code D: $5,000. Your Box 1 wages are $5,000 lower than your gross pay because traditional 401(k) contributions are pre-tax for federal income tax. Social Security and Medicare wages in Boxes 3 and 5 usually do not decrease.
- Example 2: HSA contribution (Code W) — Box 12 shows Code W: $3,200. You will generally report this on Form 8889 to reconcile contributions and distributions. If you over-contributed, you may need to address it to avoid penalties.
- Example 3: Designated Roth 401(k) (Code AA) — Box 12 shows Code AA: $2,000. This amount is included in Box 1 wages because Roth contributions are after-tax, and they are also subject to Social Security and Medicare taxes.
- Example 4: Employer health coverage cost (Code DD) — Box 12 shows Code DD: $12,400. This is informational and does not add to your taxable income. It shows the total cost of employer-sponsored health coverage.
Step-by-Step: How to Use Box 12 When You File
- Match each Box 12 letter to its description in your tax software or the IRS instructions.
- Enter the exact dollar amount shown next to each code. Do not combine or alter them.
- Watch for prompts to complete related forms, such as Form 8889 for HSA contributions or Form 8839 for adoption benefits.
- Confirm that Box 1 wages make sense given any pre-tax retirement deferrals under Codes D, E, F, G, H, and S versus Roth deferrals under Codes AA, BB, and EE.
- If you see uncollected Social Security or Medicare tax under Codes A, B, M, or N, review your filing instructions carefully because you may owe these amounts with your return.
Tips for Employees
- Compare Box 12 entries to your final pay stub for the year, especially for 401(k), 403(b), or HSA contributions.
- Keep documentation for adoption expenses, HSA or Archer MSA contributions, and stock option exercises in case you need to support your return.
- If you worked for multiple employers, review each W-2’s Box 12 carefully because codes and amounts can differ.
- Do not add Code DD to income. It is informational only.
- If something looks off, ask your employer for a corrected W-2, Form W-2c, before filing.
Tips for Employers and Payroll Teams
- Verify plan types and contribution timing so you assign the correct code, such as distinguishing a traditional 401(k) from a designated Roth 401(k).
- Coordinate with benefits providers for accurate HSA, Archer MSA, QSEHRA, and health coverage totals.
- Use the current IRS Instructions for Forms W-2 and W-3 each year to confirm any code changes.
- Audit Box 1, Box 3, and Box 5 calculations to ensure pre-tax versus after-tax treatment is consistent with Box 12 entries.
- Communicate with employees. A brief summary of their Box 12 entries can help reduce questions and filing errors.
For businesses managing year-end reporting, BoomTax offers solutions for W-2 forms and electronic filing support. If your organization also handles contractor reporting, you can explore BoomTax’s 1099 forms e-filing options as well.
Frequently Asked Questions
Do I always have Box 12 entries?
No. Many employees will not see any entries in Box 12. The presence and number of entries depend on your benefits and situations during the year.
Are Box 12 amounts taxable?
Some are, and some are not. For example, Code DD is not taxable. Code C is already included in taxable wages. Codes W or R require you to reconcile contributions on additional forms. Always follow the IRS instructions or your software’s guidance.
What if I think my Box 12 code is wrong?
Contact your employer’s payroll or HR team. If a correction is needed, they will issue a Form W-2c. Do not change the code yourself on your return.
Where can I find the full list of codes?
See the current IRS Instructions for Forms W-2 and W-3 for the official, complete list of Box 12 codes and their definitions.
Key Takeaways
- Box 12 uses letter codes to identify specific benefits and situations that may affect your return.
- Some codes are informational only, while others require additional forms or can change how your income is taxed.
- Review the codes carefully, enter them exactly as shown, and rely on IRS instructions and your tax software for the right next steps.
If you are unsure how a code applies to your situation, consult a tax professional. Understanding the Box 12 codes on Form W-2 can help prevent errors, support accurate reporting, and help you make the most of your benefits at tax time.
Need help with year-end filing? BoomTax makes it easier for businesses to prepare and e-file W-2 forms and 1099 forms accurately and on time.
This article is for general educational purposes. Always refer to the latest IRS instructions and consider professional advice for your specific circumstances.
BoomTax, The Boom Post, and its affiliates do not provide tax, legal or accounting advice. This material has been prepared for informational purposes only, and is not intended to provide, and should not be relied on for, tax, legal or accounting advice. You should consult your own tax, legal and accounting advisors prior to engaging in any transaction.