Capital Gains Tax Calculator

Investment Details

Enter your investment details to calculate capital gains tax.

$
$
$
Capital Gains Tax
$0
Net Profit After Tax$0
Gross Capital Gain$0
NIIT (3.8%)$0
Effective Rate0%
Marginal Rate0%
Tax Breakdown

Quick Summary

Calculate short-term and long-term capital gains tax using IRS rates.

Editorial Review

MT
AuthorFormula Notes

UnCalculator Math & Tech Editorial Board

Verification Team

Our verification team audits formulas, LaTeX representation, and inputs to maintain software correctness.

Editorial policy
Last audited: June 2026/Calculations: Client-side where supported
Formula last reviewed: June 2026Sources listed above

Formula Used

Tax=GaintimesRate+NIITTax = Gain \\times Rate + NIIT

Variables Explained

  • Gain = Sale Price minus Purchase Price (the capital gain)
  • Rate = Tax rate based on holding period and income level
  • NIIT = Net Investment Income Tax of 3.8% if MAGI exceeds thresholds

Step-by-Step Methodology

  1. Read user inputs from the calculator form.
  2. Validate values to ensure mathematical accuracy.
  3. Apply the appropriate formula outlined above.
  4. Round results to the relevant decimal or currency format.
  5. Display the output and generate contextual explanatory text.

Limitations

  • This calculator provides estimates only and should not replace professional advice.
  • Actual real-world results may vary based on external policies or changing rates.

Interpretation Guide

Short-term capital gains are taxed at ordinary income rates. Long-term gains receive preferential rates (0%, 15%, or 20%) based on taxable income. High earners may owe an additional 3.8% NIIT.

Sources

Change Log

v2.0: Implemented Transparent Methodology Framework.

v1.0: Initial calculator release.

Comprehensive Guide to the Capital Gains Tax Calculator

Capital gains tax is levied on profits realized from the sale of non-inventory assets such as stocks, bonds, real estate, precious metals, and cryptocurrency. This US Capital Gains Tax Calculator estimates your net tax liability by differentiating between short-term gains (taxed as ordinary income) and long-term gains (taxed at preferential rates).

Short-Term vs. Long-Term Capital Gains Rules

  • Short-Term Capital Gains (Held ≤ 1 Year): Taxed at your standard federal marginal income tax rate (10% to 37%).
  • Long-Term Capital Gains (Held > 1 Year): Eligible for preferential federal tax rates of 0%, 15%, or 20% depending on taxable income thresholds.

Net Investment Income Tax (NIIT)

High-income taxpayers are subject to an additional 3.8% Net Investment Income Tax (NIIT) on investment returns (including capital gains) if Modified Adjusted Gross Income (MAGI) exceeds $200,000 for single filers or $250,000 for married couples filing jointly.

Tax Loss Harvesting Strategy

Investors can offset capital gains against capital losses realized in the same tax year. If total losses exceed total gains, up to $3,000 of net capital losses can be deducted against ordinary income, with remaining excess losses carried forward indefinitely into future tax years.

Comprehensive US Guide: Capital gains tax calculator

This Capital gains tax calculator tool is designed for individuals and taxpayers seeking accurate financial, tax, and loan calculations in the United States. Navigating US financial regulations, tax brackets, and lending standards requires evaluating both gross amounts and long-term net outcomes under federal and state rules.

How the Capital gains tax calculator Engine Operates

The mathematical model evaluates your input parameters using current regulatory limits, standard interest compounding, and statutory tax schedules. Whether estimating monthly loan obligations or tax liabilities, the engine processes calculations instantly within your browser for complete privacy.

Key Rules & Regulatory Guidelines

  • Federal & State Mandates: Ensure calculations account for federal limits, applicable deductions, and regional variations.
  • Pre-Tax vs. Post-Tax Impact: Pre-tax contributions lower Adjusted Gross Income (AGI), reducing immediate tax burden while compounding future growth.
  • Annual Indexation: Limits and statutory thresholds are updated annually by federal agencies to match inflation indexes.

Practical Application & Strategy

When modeling your financial scenarios, test conservative, moderate, and aggressive assumptions. Factoring in secondary costs (such as insurance, escrow, or administrative fees) produces a realistic representation of your true cash flow requirements.

Common Planning Pitfalls

  • Ignoring Secondary Fees: Underestimating total costs by focusing strictly on principal and interest without escrow or tax additions.
  • Static Assumptions: Assuming variable rates or income remain fixed without stress-testing potential market changes.

Capital gains tax is a levy applied to the profit realized from the sale of a non-inventory asset, such as stocks, bonds, precious metals, or real estate.

Last updated: July 2026

Reviewed by: UnCalculator Editorial Team

Embed this Calculator

Add the Capital Gains Tax Calculator to your website or blog. Free, responsive, and customizable.

Get Embed Code

Frequently Asked Questions

What is the difference between short-term and long-term capital gains?
Short-term capital gains apply to assets held for one year or less and are taxed at your ordinary income tax rate. Long-term capital gains apply to assets held for more than one year and receive preferential tax rates of 0%, 15%, or 20% depending on your taxable income.
When does the 0% long-term capital gains rate apply?
The 0% rate applies if your taxable income is up to $47,025 for single filers or up to $94,050 for married filing jointly. This is a significant benefit for lower and middle-income investors.
What is the Net Investment Income Tax (NIIT)?
The NIIT is an additional 3.8% tax on net investment income, including capital gains, for taxpayers with modified adjusted gross income (MAGI) exceeding $200,000 (single) or $250,000 (married filing jointly).
How does tax-loss harvesting work?
Tax-loss harvesting involves selling investments at a loss to offset capital gains. You can deduct up to $3,000 in net capital losses against ordinary income per year. Unused losses carry forward to future tax years.
ADVERTISEMENT
Offline Mode: Calculators continue to run locally in your browser.