How do proceeds and cost basis taxes actually work when you sell stock?

Finally sold some shares I had been sitting on for a few years and now I have a 1099-B in front of me and I am more confused than when I started. The form shows "proceeds" in box 1d and "cost or other basis" in box 1e, and my brokerage's tax center is showing a gain number I don't fully trust. I know proceeds and cost basis taxes are connected — the gain or loss is the difference — but I don't know which form I actually put this on, whether short-term vs long-term changes anything practical, or what happens if the basis number on the 1099-B is just wrong. I tried reading the Schedule D instructions and got lost around the Form 8949 part. Can someone walk me through how the proceeds and the basis flow from the 1099-B to the return?

32 comments

The basic flow is: proceeds minus cost basis equals your gain or loss. That gain or loss goes on Form 8949 first, then the totals from Form 8949 carry to Schedule D, which feeds line 7a of Form 1040. The critical split is short-term vs long-term. If you held the shares more than 1 year, any gain or loss is long-term (Part II of Form 8949, boxes D/E/F). One year or less is short-term (Part I, boxes A/B/C). The holding period starts the day after you bought and ends on the trade date you sold — not settlement date.

Wes R.

Author

Trade date, not settlement date — that's the part I had wrong. My broker shows both and I was using the wrong one to count days. That changes whether one of my lots is short or long-term.

Which box you check on Form 8949 depends on whether the basis was reported to the IRS. Box 1f on your 1099-B says whether it was. If box 1f says basis reported, you use box A (short-term) or D (long-term). If basis was not reported to the IRS, it's box B or E. No 1099-B at all means box C or F. This matters because the correction path is different depending on the box.

Boxes G through L are the new ones for digital assets — different from stock, don't use C or F for crypto anymore.

Correct. The 2025 Form 8949 added G/H/I for short-term digital assets and J/K/L for long-term. Stock still uses A through F.

If the basis in box 1e on your 1099-B is wrong, you don't just ignore the number. With box A or D checked (basis reported to IRS), you enter the wrong basis from the 1099-B in column (e) anyway, then put a code B in column (f) and correct it in column (g) with the difference — negative in parentheses if the real basis is higher. The instructions for Form 8949 spell this out.

Wes R.

Author

That's what was tripping me up. I thought I could just type in the right number. Entering the 1099-B number and adjusting in column (g) makes more sense now.

Before I filed last year I uploaded my 1099-B and my broker's lot-by-lot statement to taxr.ai and it compared each row's proceeds and basis against what was on the form, flagged two lots where the adjusted cost basis from DRIP reinvestments wasn't reflected in box 1e, and listed the column (g) adjustments I needed. Worth doing before you finalize anything. On the actual rule: when basis is reported to the IRS and it's wrong, the Form 8949 instructions say to enter what the 1099-B shows in column (e) and use the adjustment in column (g). Don't skip that step.

Wes R.

Author

DRIP reinvestments is exactly the kind of thing I would have missed. My broker's cost basis tracking goes back years and I'm not confident every dividend reinvestment got picked up correctly.

One practical thing: if all your transactions have basis reported to the IRS and there are no adjustments needed, you can skip Form 8949 for those and report the totals directly on Schedule D line 1a (short-term) or line 8a (long-term). That's Exception 1 in the Form 8949 instructions. Saves a lot of rows if you have a lot of trades.

Worth mentioning that Exception 1 only applies when there are zero adjustments. Any wash sale, any basis correction, any code at all in column (f) — that lot has to go on Form 8949 individually.

Right. Exception 1 is clean transactions only. Mixed batches need to be separated.

The holding period rule also covers inherited shares — property inherited from a decedent is automatically long-term regardless of how long you actually held it. That's in Publication 550. Doesn't apply here but it surprises people.

Had a similar situation with multiple accounts and lots from different years all coming in on one 1099-B. I uploaded the whole document to Taxr and it sorted the lots by holding period, identified which ones had wash sale codes in box 1g, and drafted the Form 8949 entries with the W codes already placed in column (f). Saved me from manually counting which lots were long vs short. On wash sales specifically: box 1g shows the disallowed loss only when both the sold and repurchased shares are covered securities with the same CUSIP bought in the same account. If those conditions aren't met, the 1099-B might not flag it even though the wash sale rule still applies.

Wes R.

Author

Same account and same CUSIP — I didn't know the 1099-B only flags it under those specific conditions. So I could technically have a wash sale the form doesn't warn me about.

Exactly. The wash sale window is 30 days before or after the sale. If you bought the same stock in a different account, or if your spouse bought it, the form won't flag it but the loss is still disallowed.

The disallowed wash sale loss doesn't disappear — it gets added to the cost basis of the replacement shares. So you do recover it eventually when you sell those shares, unless you trigger another wash sale.

Wes R.

Author

Basis step — noted. So the tax doesn't go away, it just shifts.

Something people get wrong: the proceeds in column (d) of Form 8949 should always be what the 1099-B or 1099-DA shows, even if you think the number is off. If the proceeds are wrong you adjust in column (g), same as basis. Don't just type in a different number in column (d).

If your losses end up exceeding your gains for the year, you can use the net loss to offset other income, but only up to the limit — the instructions for Schedule D and Topic 409 on the IRS site cover the exact figure. Whatever you can't use carries forward to the next year. The carryover worksheet is in Publication 550.

Carryover step — this tripped me up the first year I had a big loss year. You have to figure the carryover with the worksheet or the Schedule D instructions; you can't just roll the number forward manually.

The 1099-B has specific boxes to know: 1d is proceeds, 1e is cost or other basis, 1f is the reporting indicator (whether basis went to IRS), 1g is wash sale loss disallowed. Run through those four before you even open Form 8949.

Wes R.

Author

This is the clearest the boxes have been explained to me. Printing this out next to my 1099-B.

To be direct about the flow for your situation: 1099-B to Form 8949 (one row per lot or one aggregated block if Exception 1 applies), then totals from Form 8949 Part I line 2 to Schedule D line 1b, 2 or 3 (box A, B or C), Part II line 2 to Schedule D line 8b, 9 or 10 (box D, E or F), then Schedule D total to Form 1040 line 7a. That's the whole chain.

Wes R.

Author

Lot detail step — downloaded it and there are definitely some lots with acquisition dates I need to verify.

Publication 550 and Publication 551 are both worth having open. 550 covers the holding period rules and wash sale rules in full. 551 covers how to figure your basis in the first place — especially relevant if you got shares as a gift, inherited them, or received them through a split or spinoff.

To be direct about the flow for your situation: 1099-B to Form 8949 (one row per lot or one aggregated block if Exception 1 applies), then totals from Form 8949 Part I line 2 to Schedule D line 1b, Part II line 2 to Schedule D line 8b, then Schedule D total to Form 1040 line 7. That's the whole chain.

Wes R.

Author

Line chain — that's what I needed. I kept losing track of where numbers were supposed to land.

Worth adding: Schedule D line 1a gets the Exception 1 short-term totals (if any), and line 8a gets the Exception 1 long-term totals. Those are separate from the 1b and 8b lines that pull from Form 8949.

If the number of lots is large or the basis adjustments are complicated — especially if there are cost basis corrections spanning multiple years — it may be worth having an enrolled agent or CPA review the Form 8949 before you file. The IRS matches 1099-B proceeds to what you report, and unexplained differences can generate a notice.

Wes R.

Author

Good checkpoint. I have about twenty lots across two accounts so I'm going to do the lot-detail reconciliation myself first, then decide if I need help.

The irs.gov/forms-pubs/about-form-8949 page has the form itself and the instructions link. The instructions for Form 8949 at irs.gov/instructions/i8949 are actually readable — they go through each column with examples. Worth thirty minutes before you start entering numbers.