Cost Basis Tracking for Tax-Loss Harvesting
How to Track Cost Basis and Maintain Harvesting Records
Tax-loss harvesting only works if you can prove your cost basis—the amount you originally paid for each position or lot of shares. Without accurate cost basis records, you can't calculate losses, you can't substantiate harvests to the IRS, and you're exposed to audit risk. The complexity multiplies when you harvest, reinvest, and track across multiple accounts over years. A $50,000 loss harvested in 2022 has value only if you can document it in 2025 when you need to offset gains. Many investors fail at harvesting not because they misunderstand the strategy but because they neglect the accounting that makes it defensible. This article covers cost basis tracking methods, tools, documentation standards, and common pitfalls that trip up even sophisticated investors.
Quick definition: Cost basis is the original price paid for a security or lot of shares. Accurate cost basis tracking allows you to calculate realized losses and gains, substantiate them to the IRS on tax returns, and support your loss-harvesting strategy with documentation.
Key takeaways
- Cost basis comes from purchase price, reinvested dividends, inherited/gifted shares, and adjustment cost basis modifications.
- The IRS shifted the burden to brokerages to report cost basis on Form 8949 (starting 2011 for stocks); verify accuracy and correct errors.
- Multiple tracking methods exist: brokerage-reported basis, taxpayer-maintained basis, and hybrid methods; pick one and stay consistent.
- Inherited shares receive stepped-up basis; document the valuation date and amount to support tax returns.
- Dividend reinvestments and tax harvesting resets your cost basis; track these adjustments scrupulously or you'll overstate gains or losses.
What Is Cost Basis?
Cost basis is the original cost of an investment, used to calculate gain or loss when you sell. It includes:
- Purchase price: The amount you paid to buy the security.
- Commissions and fees: Trading costs paid to acquire the position.
- Reinvested dividends and interest: When dividends are automatically reinvested, they increase cost basis.
- Capitalized expenses: Return-of-capital distributions that adjust basis downward.
- Inherited basis: Stepped-up basis at the date of death for inherited securities.
- Gifted shares: Original donor's cost basis carries over (carryover basis).
Example: Dividend reinvestment increasing basis
You buy 100 shares of a dividend stock at $50 per share = $5,000 cost basis. Over three years, the stock pays $5 per share in annual dividends. You reinvest all dividends:
- Year 1: $500 dividend reinvested at $55/share = 9.09 more shares, cost basis: $5,500
- Year 2: $545 dividend reinvested at $60/share = 9.08 more shares, cost basis: $6,045
- Year 3: $595 dividend reinvested at $65/share = 9.15 more shares, cost basis: $6,640
You now own 127.32 shares with a total cost basis of $6,640. If you sell at $70/share, your proceeds are $8,912, and your gain is $2,272 (not $2,700 as you'd calculate if you forgot dividend reinvestment basis adjustments).
Cost Basis Tracking Methods
Method 1: Brokerage-Reported Basis (Modern Default)
Starting in 2011, the IRS required brokerages to report cost basis on Form 8949 (Sales of Capital Assets) for all securities sold. This is the modern standard and is now the default method for most investors.
How it works:
- Your brokerage tracks cost basis automatically from purchase records.
- When you sell a security, the brokerage reports the cost basis on Form 8949.
- You use the reported basis to calculate gain/loss on your tax return.
Advantages:
- Automatic and transparent.
- IRS already has a copy of the report, reducing audit risk.
- Brokerage handles the accounting, reducing your burden.
Disadvantages:
- Brokerages sometimes make errors (especially with inherited shares, transfers, or dividend reinvestments).
- If you transfer securities between brokerages, cost basis may not transfer accurately.
- Older positions (pre-2011) may not have basis data available.
Best practice: After each year, download your brokerage's Form 8949 report and verify it against your own records. Especially verify:
- Inherited or gifted positions (stepped-up basis should reflect fair market value at date of death, not original cost).
- Securities transferred from other brokerages (basis may default to zero or be understated).
- Dividend-reinvestment positions (basis should include all reinvested amounts).
Method 2: Taxpayer-Maintained Records (Legacy or Complex Situations)
For older accounts, inherited securities, or positions held before brokerage reporting, you may maintain your own cost basis records separately from the brokerage.
How it works:
- You keep detailed records of all purchases, sales, and reinvestments.
- You calculate cost basis yourself using a method: FIFO, specific ID, average-cost, or other IRS-approved method.
- You reconcile your records with brokerage statements annually.
Advantages:
- Full control and transparency, especially for inherited or multi-decade positions.
- Allows specific identification without relying on brokerage systems.
- Useful for positions that span multiple brokerages.
Disadvantages:
- Labor-intensive and error-prone.
- If discrepancies arise, you bear the burden of proof.
- Requires meticulous record-keeping and documentation.
Best practice: If you use taxpayer-maintained records, document the source of basis data (original purchase confirmation, gift letter, inheritance valuation) and keep these documents indefinitely. Reconcile monthly with brokerage statements.
Method 3: Hybrid Approach (Professional Investors)
Many sophisticated investors use a hybrid: trust the brokerage for reporting but maintain secondary records for verification and tax-loss harvesting optimization.
How it works:
- Brokerage reports cost basis on Form 8949 (primary source).
- You maintain a spreadsheet tracking tax lots, harvest dates, reinvestments, and wash-sale windows.
- You use this spreadsheet to select which lots to harvest (specific ID) and to track carryforwards.
Advantages:
- Leverages brokerage accuracy while maintaining harvesting precision.
- Reduces audit risk (IRS sees the Form 8949 match).
- Enables optimized lot selection without overwhelming paperwork.
Best practice: Use a spreadsheet or specialized tax software. Update it after every trade and rebalancing event.
Tracking After Tax-Loss Harvesting
When you harvest a loss and reinvest proceeds, your cost basis resets. This creates a tracking requirement:
Example: Harvest and reinvestment resetting basis
You own 500 shares of Vanguard Total Stock Market Index (VTSAX, a mutual fund):
- Original purchase: 100 shares at $60 = $6,000 (Tranche 1)
- Reinvested dividends: 50 shares at $70 = $3,500 (Tranche 2)
- Additional purchase: 350 shares at $75 = $26,250 (Tranche 3)
- Total cost basis: $35,750 for 500 shares
Today, VTSAX trades at $50. Your position is worth $25,000 (loss: $10,750).
You decide to harvest losses. Using specific ID, you sell 100 shares of Tranche 1, realizing a $1,000 loss ($6,000 - $5,000). You immediately reinvest $5,000 in a different total-market fund (e.g., iShares Total U.S. Stock Market ETF (ITOT)) at $50/share = 100 shares.
Your new cost basis structure is:
| Fund | Tranche | Shares | Cost | Current Value | Basis per Share |
|---|---|---|---|---|---|
| VTSAX | 2 (original) | 50 | $3,500 | $2,500 | $70 |
| VTSAX | 3 (original) | 350 | $26,250 | $17,500 | $75 |
| ITOT | 4 (reinvestment) | 100 | $5,000 | $5,000 | $50 |
Your total cost basis is now $34,750. If the market recovers and both funds trade at $60/share:
- VTSAX 50 shares worth $3,000; gain: -$500 (loss)
- VTSAX 350 shares worth $21,000; gain: -$5,250 (loss)
- ITOT 100 shares worth $6,000; gain: $1,000 (gain)
If you later sell the ITOT position at $60, you'd realize a $1,000 gain. But if you later sell the VTSAX positions (Tranches 2–3), you'd realize losses. This is why tracking after harvesting is critical—your portfolio now has mixed cost bases, and any further sales need precise lot selection to optimize remaining opportunities.
Cost Basis Tracking Workflow
Documentation Standards for IRS Compliance
The IRS doesn't require you to file cost basis records with your tax return, but you must maintain them to substantiate Form 8949 if audited.
What to document:
- Original purchase confirmations: Broker statements showing the date, quantity, and price of the initial purchase.
- Reinvestment records: Statements showing dividend or interest reinvestments, including the date and reinvested amount.
- Transfer documents: Confirmation statements if you transfer securities between brokerages (showing cost basis data).
- Inherited asset valuations: Estate documents or appraisals showing the fair market value at the date of death (stepped-up basis).
- Gift documentation: If you receive gifted securities, obtain a letter from the donor stating their cost basis (carryover basis).
- Tax-loss harvest records: Spreadsheet or log showing:
- Date of harvest
- Security sold and quantity
- Specific lot sold (if applicable)
- Loss realized
- Reinvestment security and date
- Wash-sale windows (30 days before/after)
- Form 8949 copies: Printed or saved copies of the annual Form 8949 your brokerage files with the IRS.
Retention: Keep all cost basis documentation for at least seven years after you sell the position (or longer if you carry forward losses). The IRS has a three-year audit window for most returns, but a six-year window for underreported income and a seven-year window for poor records. Inherited positions may require indefinite retention (the stepped-up basis is relevant for decades).
Common Tracking Errors
Error 1: Reinvestment dividends forgotten
You buy 100 shares at $50 (cost basis: $5,000). Over 10 years, you reinvest $2,000 in dividends. Your total cost basis should be $7,000, but if you never documented the reinvestments, you might calculate basis as $5,000. When you sell at $75/share ($7,500), you'd report a $2,500 gain (correct is $500 gain). You've overstated your gain and paid tax on phantom income.
Fix: Reconcile your cost basis against historical brokerage statements. Trace every dividend reinvestment.
Error 2: Transferred positions losing basis data
You transfer 500 shares of Apple from Brokerage A to Brokerage B. Brokerage B doesn't receive the cost basis data properly and defaults to zero (or lowest-cost assumptions). When you sell, Brokerage B reports incorrect basis, creating an inflated gain.
Fix: Before transferring securities, get a cost basis report from the sending brokerage. Provide it to the receiving brokerage. Verify the transfer cost basis on your receiving statement. Correct any errors immediately.
Error 3: Wash sales triggering double-counting
You harvest a loss on January 15, realizing a $5,000 loss. You buy back the same security on February 1 (triggering a wash sale). The loss is disallowed, and your new cost basis is adjusted to the sale price, not the original cost. But if you incorrectly track your original cost basis as still applying, you'll have an inflated cost basis and understate gains on future sales.
Fix: When the wash sale is disallowed, add the disallowed loss to your new cost basis. If you sold at $50,000 (original basis $55,000) and bought back at $50,000 on January 25 (wash sale), your new cost basis is $55,000 (the original), not $50,000. Track this adjustment explicitly.
Error 4: Inherited shares using wrong basis date
Your parent dies on June 15, and the estate values their Apple shares at $100/share (fair market value). You inherit the shares with a stepped-up basis of $100. But if the brokerage mistakenly uses the original cost basis ($20/share from 30 years ago), you'll overstate your cost basis, resulting in a loss (or reduced gain) when you sell.
Fix: Obtain the estate valuation or death certificate and communicate the stepped-up basis to your brokerage. Request a written confirmation that the basis has been corrected. Keep the estate valuation forever.
Error 5: Reinvestment harvest basis reset
You harvest a loss in July and reinvest. You then immediately harvest another portion of the same original position in August, forgetting you've already reset the cost basis. You double-count the harvest against the same original loss.
Fix: Use specific ID and track which lots you've harvested and when. Create a "harvested lots" log with dates and amounts to prevent double-harvesting.
Tools and Software for Cost Basis Tracking
Built-in Brokerage Tools
Most major brokerages (Vanguard, Fidelity, Schwab, Interactive Brokers) provide cost basis reports and Form 8949 generation:
- Vanguard: "Tax Lot Information" in the account dashboard shows cost basis by lot.
- Fidelity: "Lot Viewer" tool and downloadable cost basis reports.
- Schwab: "Tax Lot" interface in the platform with specific-ID selection at time of sale.
Recommendation: Use brokerage-provided tools as your primary source but verify against other records.
Specialized Tax Software
- Turbotax Investments: Integrates with brokerages to import Form 8949 data and organize cost basis.
- StockMarketEye: Portfolio tracking software that calculates unrealized gains/losses and tracks cost basis across accounts.
- GainSeeker: Specialized for tax-loss harvesting; tracks harvest dates, wash-sale windows, and carryforwards.
Spreadsheet-Based Tracking
A Google Sheet or Excel spreadsheet can suffice for simpler portfolios:
| Date | Action | Security | Quantity | Price | Cost | Current Price | Current Value | Gain/Loss | Notes |
|---|---|---|---|---|---|---|---|---|---|
| 2024-01-15 | Buy | Apple | 100 | $180 | $18,000 | — | — | — | — |
| 2024-06-20 | Harvest | Apple | 50 | $150 | $(50×180=9,000) | — | $7,500 | -$1,500 | Specific ID Tranche 1 |
| 2024-06-20 | Reinvest | VTI | 50 | $230 | $11,500 | — | — | — | Wash-sale free |
Real-World Examples
Example 1: Multi-Account Basis Coordination
James has Apple shares in three accounts:
- Taxable brokerage (500 shares, cost basis $12,000)
- Inherited IRA (200 shares, stepped-up basis at death: $9,600)
- Employee stock purchase plan account (100 shares, cost basis $8,000)
When he sells 150 shares from his taxable account, he must specify which lot. Complicating matters, 50 shares were transferred from the ESPP account, and he needs to verify the transfer cost basis is correct. By maintaining a consolidated spreadsheet tracking all three accounts and each share lot, he ensures correct Form 8949 reporting.
Example 2: Dividend Reinvestment Over Decades
Emma has owned Ford stock since 1995. She's reinvested dividends every quarter for 29 years. Her original cost basis was $2,500 (100 shares at $25), but after 116 quarters of dividend reinvestments, her position now includes 340 shares with a total cost basis of $12,000. If she sold at $15/share, her proceeds would be $5,100. Without tracking dividend reinvestments, she'd calculate a gain of $2,600 ($5,100 - $2,500), but the true gain is only -$6,900 (a loss!). By maintaining reinvestment records (either from her brokerage statements or a personal spreadsheet), she calculates correctly.
Example 3: Inherited Shares with Stepped-Up Basis
Michael's grandmother dies with a $500,000 portfolio of dividend stocks. The estate values these stocks on the date of death at $520,000 (total appreciated value). Michael inherits the shares with a stepped-up basis of $520,000 (the date-of-death value). If the stocks later decline to $480,000, he has a loss of $40,000, which he can harvest. However, if he incorrectly uses his grandmother's original cost basis (say, $200,000 from 40 years ago), he'd calculate a gain of $280,000 instead of a loss. Documenting the stepped-up basis with the estate valuation prevents this catastrophic error.
Common Mistakes
Mistake 1: Relying on brokerage basis without verification Brokerages make errors. A transferred position might arrive with zero basis, or dividend reinvestments might be omitted. Don't assume the brokerage is always correct; verify annually and correct errors in writing.
Mistake 2: Losing documentation after a sale You sell a position and think you're done tracking. But if you inherit the position later or need to explain the sale during an audit, missing documentation is costly. Keep all cost basis records indefinitely.
Mistake 3: Mixing cost basis methods across accounts You use average-cost in your taxable brokerage but specific ID in your individual account. This creates confusion and audit risk. Choose one method per account and stay consistent.
Mistake 4: Not adjusting basis after wash sales A wash sale disallows the loss and adjusts your new cost basis upward. If you don't document this adjustment, future sales will use an incorrect basis. Explicitly track wash-sale adjustments.
Mistake 5: Assuming inherited basis is automatically stepped-up Inherited shares are not automatically stepped-up in your brokerage system. You must provide the estate valuation date and amount. Contact your brokerage and request a cost-basis correction form.
FAQ
What if I've lost my original purchase confirmations?
Request historical statements from your brokerage. Most brokerages retain records for at least 7 years (some indefinitely). If the position transferred between brokerages, ask both for records. If truly unavailable, you can estimate basis using historical stock prices (but this is weak in an audit).
Do I have to use the brokerage's reported cost basis?
You're allowed to correct the brokerage's reported basis on your tax return if you have documentation supporting a different amount (e.g., different purchase price, reinvested dividends). File Form 8949 with your corrections and attach explanatory notes.
What happens if I understate my cost basis on my tax return?
You'd overstate your gain and pay more tax than owed. If audited and you can't substantiate the lower basis, the IRS may assess back taxes plus penalties and interest. Conversely, if you overstate basis (understate gain), the IRS will assess the difference plus penalties.
Do I have to track wash sales on my tax return?
No, you don't file a "wash sale" form. Instead, the IRS expects you to adjust your cost basis for the disallowed loss. This adjustment is reflected in your future Form 8949 when you eventually sell the washed-sale position. But you must document the adjustment internally to avoid future errors.
How long do I have to keep cost basis records?
At least 7 years. Keep them indefinitely if you're still holding the position or if you're carrying forward losses.
Can I change my cost basis method after the fact?
Changing from average-cost to specific ID for mutual funds may require IRS approval on Form 3115. Changing FIFO to specific ID is simpler but should be done at the time of sale, not retroactively. Avoid changing methods once elected.
Related concepts
- Tax-Loss Harvesting Basics
- Tax Lot Selection for Harvesting
- The Wash-Sale Rule
- Capital Gains and Holding Periods
- Estate and Gift Tax Basics
Summary
Accurate cost basis tracking is the unglamorous but essential foundation of tax-loss harvesting. Cost basis includes purchase price, commissions, reinvested dividends, and stepped-up valuations for inherited shares. Brokerages now report cost basis on Form 8949, but errors occur—especially with transfers, reinvestments, and inherited positions. Maintain hybrid records: trust the brokerage for the primary report but verify against your own spreadsheet or software, particularly after harvests, reinvestments, or wash sales. Document everything: original confirmations, reinvestment records, harvest dates, and basis adjustments. Retention should span at least 7 years and indefinitely for positions still held. The difference between meticulous tracking and casual record-keeping is the difference between defensible tax returns and audit risk, between calculated tax efficiency and inadvertent overpayment.