Updated October 17, 2026. Quick answer: Code X on Form 8949 marks a gain you are excluding under the DC Zone asset or qualified community asset rules in the Schedule D instructions. The instructions say to “Report the sale or exchange on Form 8949 as you would if you weren’t taking the exclusion.” The exclusion amount then goes in column (g) as a negative number, with X in column (f).
What code X means
The Form 8949 instructions send you to the Schedule D instructions for this code. The condition is that you “can exclude all or part of your gain under the rules explained in the Schedule D instructions for DC Zone assets or qualified community assets”. Those are two narrow, older rules, and neither is the same as the home sale exclusion on Form 8949 code H or the small business stock exclusion on Form 8949 code Q.
The DC Zone asset rule
The Schedule D instructions describe the first rule: “If you sold or exchanged a District of Columbia Enterprise Zone (DC Zone) asset that you acquired after 1997 and before 2012 and held for more than 5 years, you may be able to exclude the amount of qualified capital gain that you would otherwise include in income.” The scope is limited: “The exclusion applies to an interest in, or property of, certain businesses operating in the District of Columbia.”
The instructions name three kinds of DC Zone asset: “DC Zone business stock.” “DC Zone partnership interest.” and “DC Zone business property.” The exclusion covers only qualified capital gain, and the instructions list gains that do not count. One of them is “Gain attributable to periods after December 31, 2016.” Another is “Gain treated as ordinary income under section 1245.”
The qualified community asset rule
The second rule is similar but covers a different set of assets and dates: “If you sold or exchanged a qualified community asset that you acquired after 2001 and before 2010 and held for more than 5 years, you may be able to exclude the qualified capital gain that you would otherwise include in income.” “The exclusion applies to an interest in, or property of, certain renewal community businesses.” For this rule the instructions exclude, among other items, “Gain attributable to periods after December 31, 2014.” The holding period for both rules is the 5 years the instructions state; the 5-year idea in the stock exclusion on the QSBS 5-year holding period page is a different rule with its own conditions.
What to enter in column (g)
For the code X row, the table in the instructions says “Report the sale or exchange on Form 8949 as you would if you weren’t taking the exclusion. Then enter the amount of the exclusion as a negative number (in parentheses) in column (g).”
The Schedule D instructions give the same steps by asset type: “Report the sale or exchange of DC Zone business stock or a DC Zone partnership interest on Form 8949, Part II, as you would if you weren’t taking the exclusion.” “Then enter “X” in column (f).” For community assets: “Report the sale or exchange of qualified community stock or a qualified community partnership interest on Form 8949, Part II, with the appropriate box checked, as you would if you weren’t taking the exclusion.” The box rules are in the box A to L guide.
As a computed illustration, not an IRS example: suppose column (d), the proceeds, is $90,000, column (e) is $40,000, and the whole $50,000 gain qualifies for the exclusion. Computing column (h): column (g) is ($50,000), and column (h) is $90,000 minus $40,000 minus $50,000, which is $0.
Business property does not go on Form 8949
Only the stock and partnership interests go on this form. The Schedule D instructions say “Report the sale or exchange of DC Zone business property on Form 4797.” For community assets the same applies: “Report the sale or exchange of qualified community business property on Form 4797.”
Setting up the row
Columns (f) and (g) work as a pair. “In order to explain any adjustment to gain (or loss) in column (g), enter the appropriate code(s) in column (f).” The dollar side is described this way: “Enter in this column any necessary adjustments to gain (or loss). Enter negative amounts in parentheses.” Most rows need neither: “For most transactions, you don’t need to complete columns (f) and (g) and can leave them blank.”
If a row needs more than one code, the instructions say “Don’t separate the codes by a space or comma.” They also give the rule for the dollar amount: “If you entered more than one code in column (f) on the same row, enter the net adjustment in column (g).”
Where it goes next
Column (h) is where the adjustment lands. The instructions say “First, subtract the cost or other basis in column (e) from the proceeds (sales price) in column (d). Then take into account any adjustments in column (g). Enter the gain (or loss) in column (h).”
The row then flows to the summary. “The total of the amounts in column (h) of line 2 of all your Forms 8949 should equal the amount you get by combining columns (d), (e), and (g) on the corresponding line of Schedule D (Form 1040).” The Schedule D page explains the lines that total comes from, and the Form 8949 instructions page covers the form as a whole.
Edition and line numbers
This page reads the 2025 Form 8949 and its 2025 instructions, along with the 2025 Instructions for Schedule D (Form 1040) (and Publication 550 for 2025 returns where it is cited), the current files irs.gov served on 2026-10-17. They are the forms for the tax year 2025 return, filed in 2026. Check the tax year printed on the form you are filling in and use the column letters and codes on that year’s form, because a different year’s form can letter its columns or word its codes differently.
Common mistakes
- Entering only the taxable part of the sale. The instructions say to “Report the sale or exchange on Form 8949 as you would if you weren’t taking the exclusion.” The full proceeds and basis go in columns (d) and (e).
- Entering the exclusion as a positive number. The instructions say to “enter the amount of the exclusion as a negative number (in parentheses) in column (g).”
- Putting business property on Form 8949. The Schedule D instructions say “Report the sale or exchange of DC Zone business property on Form 4797.”
Related: QSBS 5-year holding period, Capital gains tax calculator, Form 1099-B box 2, Form 8949 instructions, and Schedule D.
Sources
- Instructions for Form 8949 (2025): https://www.irs.gov/pub/irs-pdf/i8949.pdf
- Instructions for Schedule D (Form 1040) (2025): https://www.irs.gov/pub/irs-pdf/i1040sd.pdf
Read from the IRS documents linked above on October 17, 2026. General information, not tax advice. Your own facts decide the outcome, and a preparer, the account provider or the IRS is the right place to confirm anything consequential.