Analysis
Free Instant No Signup 7-Day Money-Back

Trading Tax Estimator (CapitalGains)

Estimate capital gains tax on your trades. Covers US short-term vs long-term rates, NIIT, wash sales, and India's post-Budget 2024 equity and F&O tax rules.

%
Position Size shares
Risk Amount
Risk Per Share
Total Position Value

Results update instantly as you type

Quick Answer

The capital gains tax on trades equals short-term gains taxed at ordinary income rates (10–37%) plus long-term gains at 0/15/20%, with a 3.8% NIIT surcharge above $200k MAGI.

US Tax = (Net ST Gains × Ordinary Rate) + (Net LT Gains × LT Rate) + max(0, MAGI - Threshold) × 3.8%

The trading tax estimator calculates your estimated capital gains tax liability across a full year of trading, accounting for mixed holding periods, loss offsets, and jurisdiction-specific rules that generic tax calculators ignore. The core formula separates net short-term gains (taxed at ordinary income rates) from net long-term gains (taxed at preferential rates), then checks whether your combined income triggers the NIIT surcharge. The calculator above produces instant estimates for both US and Indian traders.

How to Use

InputWhat to EnterExample
JurisdictionUS or IndiaUS
Short-Term GainsNet gains from positions held 365 days or fewer$68,000
Long-Term GainsNet gains from positions held 366+ days$5,000
Capital Loss CarryforwardUnused losses from prior years$0
Ordinary IncomeW-2 wages, salary, or business income$85,000
Filing StatusSingle, MFJ, or HoH (US)Single

The estimator outputs federal (or central) tax, the NIIT surcharge where applicable, your effective rate on trading gains, and after-tax profit. State taxes are not included — for California, add approximately 13.3% on all gains; for New York, approximately 10.9%.

Formula Explained

US Tax = (Net ST Gains × Ordinary Marginal Rate)
       + (Net LT Gains × LT Rate)
       + max(0, MAGI - NIIT Threshold) × 3.8%

Net short-term gains stack directly on top of ordinary income when determining your marginal bracket. A trader with $85,000 in W-2 income and $68,000 in net short-term gains has $153,000 in ordinary income — well within the 22% bracket for a single filer in 2024 (which extends to $100,525 before reaching 24%).

Net long-term gains are taxed on a separate schedule. For single filers in 2024: 0% on gains when total taxable income is at or below $47,025; 15% from $47,026 up to $518,900; 20% above $518,900 (IRS Rev. Proc. 2023-34). Many traders who expect to owe 20% discover they qualify for the 15% rate.

The NIIT surcharge of 3.8% applies to net investment income when MAGI exceeds $200,000 for single filers or $250,000 for married filing jointly — thresholds unchanged since 2013. The surcharge is calculated on the lesser of (a) net investment income or (b) the amount MAGI exceeds the threshold. At the top federal bracket, the combined rate reaches 23.8% for long-term gains and up to 40.8% for short-term gains.

For India, the post-Budget 2024 rates apply a flat 20% on STCG for listed equity where STT has been paid, and 12.5% on LTCG above the ₹1,25,000 annual exemption. If your total LTCG for the year is below ₹1,25,000, the tax is zero regardless of holding period. Futures and options income is classified by the Supreme Court and CBDT as non-speculative business income — it is taxed at your income slab rate (up to 30%), not at capital gains rates.

Example Calculations

Scenario 1: US Trader — Mixed Holding Periods with Loss Harvest

  • Ordinary Income: $85,000 (W-2)
  • NVDA trade: 200 shares bought at $450, sold at $850 after 8 months = $80,000 short-term gain
  • SPY trade: 100 shares bought at $480, sold at $530 after 14 months = $5,000 long-term gain
  • Loss harvest: Losing position closed for -$12,000 short-term loss
  • Net short-term: $68,000 | Net long-term: $5,000

Combined ordinary income of ~$153,000 stays under the NIIT threshold of $200,000. Federal tax: $68,000 × 22% = $14,960 on short-term gains; $5,000 × 15% = $750 on long-term gains. Total: $15,710.

Without the $12,000 loss harvest, short-term gains would be $80,000, pushing estimated federal tax to ~$18,400 — a $2,690 difference from one deliberate position close before year-end.

Scenario 2: Indian Equity Trader — STCG vs. LTCG Timing

  • Position: 100 shares of Reliance, bought at ₹2,400, sold at ₹2,900 = ₹50,000 gain
  • Holding period: 10 months → STCG at 20% → ₹10,000 tax
  • Holding period: 12+ months → LTCG at 12.5%, but ₹50,000 falls entirely within the ₹1,25,000 annual exemption → ₹0 tax

Waiting two additional months before selling eliminates the entire ₹10,000 liability. This timing advantage disappears once cumulative LTCG for the year exceeds ₹1,25,000 — beyond that threshold, the 12.5% rate applies to every additional rupee.

Scenario 3: Indian F&O Trader

  • Gross F&O profit: ₹3,00,000 in a tax year
  • Classification: Non-speculative business income (not capital gains)
  • Tax at 30% slab rate: ₹90,000

The same ₹3,00,000 earned from equity delivery would be classified as LTCG and taxed at 12.5% (₹37,500 above the exemption). F&O traders pay roughly 2.4x more tax on equivalent profits than equity delivery traders in the top slab — a structurally important difference when evaluating instrument choice.

When to Use This Tax Estimator

  • Before year-end tax-loss harvesting: Quantify how much a deliberate loss realization saves in current-year federal tax, then weigh it against the wash sale 30-day lockout window.
  • Estimating quarterly estimated taxes: US traders with significant trading income owe estimated taxes quarterly. Use the estimator after each quarter to avoid underpayment penalties.
  • Evaluating hold-or-sell decisions: When a position approaches the 366-day threshold, the estimator shows the exact dollar difference between closing now (short-term rate) versus waiting (long-term rate).
  • NIIT cliff awareness: If your combined income approaches $200,000 single / $250,000 MFJ, model the NIIT impact before realizing additional gains — crossing the threshold adds 3.8% on all net investment income, not just the amount above the line.
  • India Budget 2024 recalibration: Traders who built strategies around pre-July 2024 rates (15% STCG, 10% LTCG) need to rerun their net-of-tax return assumptions. The rate change is not retroactive but applies to all sales from July 23, 2024 onward.
  • Day Trading Tax Calculator — Focused on frequent intraday traders, including Section 475 MTM election modeling and wash sale impact for high-volume accounts.
  • Crypto Tax Calculator — Applies the same short/long holding period rules to cryptocurrency disposals, where every swap or sale is a taxable event.
  • Stock Profit Calculator — Calculates gross pre-tax profit on individual equity trades, useful for computing the gross gain before running it through the tax estimator.
  • Trading Fee Calculator — Quantifies brokerage and exchange costs, which reduce gross gains and therefore reduce the taxable base entered into this estimator.

Frequently Asked Questions

How do you calculate capital gains tax on stock trades?

Separate your trades into short-term (held 365 days or fewer) and long-term (held 366+ days). Net each group independently — losses offset gains within the same category first, then short-term losses can offset long-term gains. Tax short-term net gains at your marginal ordinary income rate and long-term net gains at 0%, 15%, or 20% depending on total taxable income. If MAGI exceeds $200,000 (single), add the 3.8% NIIT on the lesser of net investment income or excess MAGI.

What is the capital gains tax rate for short-term trades in the US?

Short-term capital gains — from positions held 365 days or fewer — are taxed as ordinary income at federal rates from 10% to 37%, depending on your total taxable income and filing status. There is no preferential rate for short-term gains.

How many days must you hold a stock to get long-term capital gains treatment?

In the US, a position must be held for more than 365 days — meaning at least 366 days — to qualify for long-term capital gains rates. Selling on day 365 still triggers short-term rates. One day determines whether you pay 22% or 15% on the same gain.

What is the Net Investment Income Tax (NIIT) and does it apply to traders?

The NIIT is a 3.8% surcharge on net investment income (capital gains, dividends, interest) for taxpayers whose Modified Adjusted Gross Income exceeds $200,000 (single) or $250,000 (married filing jointly). It effectively raises the top long-term rate to 23.8% and the top short-term rate to 40.8% for high-income traders.

Does the wash sale rule affect capital gains calculations for active traders?

Yes. If you sell a security at a loss and repurchase the same or substantially identical security within 30 days before or after the sale, the IRS disallows that loss under the wash sale rule. The disallowed loss is added to the cost basis of the replacement shares rather than deducted in the current year, which inflates taxable gains until the replacement position is eventually closed.

How to Calculate

1

Enter your inputs

Fill in the required fields in the calculator.

2

Review your results

The calculator instantly shows your results as you type.

Common Questions

What is the capital gains tax rate for short-term trades in the US?

Short-term capital gains — from positions held 365 days or fewer — are taxed as ordinary income at federal rates from 10% to 37%, depending on your total taxable income and filing status. There is no preferential rate for short-term gains.

How many days must you hold a stock to get long-term capital gains treatment?

In the US, a position must be held for more than 365 days — meaning at least 366 days — to qualify for long-term capital gains rates. Selling on day 365 still triggers short-term rates. One day determines whether you pay 22% or 15% on the same gain.

What is the Net Investment Income Tax (NIIT) and does it apply to traders?

The NIIT is a 3.8% surcharge on net investment income (capital gains, dividends, interest) for taxpayers whose Modified Adjusted Gross Income exceeds $200,000 (single) or $250,000 (married filing jointly). It effectively raises the top long-term rate to 23.8% and the top short-term rate to 40.8% for high-income traders.

How did India's Budget 2024 change capital gains tax on stocks?

Effective July 23, 2024, the Finance Act 2024 raised STCG on listed equity (STT-paid) from 15% to 20%, and raised LTCG from 10% to 12.5%. The annual LTCG exemption also increased from ₹1,00,000 to ₹1,25,000. F&O income remains classified as business income taxed at slab rates, not capital gains.

Does the wash sale rule affect capital gains calculations for active traders?

Yes. If you sell a security at a loss and repurchase the same or substantially identical security within 30 days before or after the sale, the IRS disallows that loss under the wash sale rule. The disallowed loss is added to the cost basis of the replacement shares rather than deducted in the current year, which inflates taxable gains until the replacement position is eventually closed.

Track Your Trading Performance

JournalPlus automatically tracks your risk metrics, position sizes, and performance analytics for every trade.

SSL Secure
One-Time Payment
7-Day Money-Back
4.9/5 (1,287 reviews)