TToolWise Digital Shop on Etsy →

Free tools

Capital Gains Tax Calculator

Estimate your federal long-term capital gains tax — 0%, 15%, or 20% depending on your income — plus your after-tax proceeds.

Quick answer: Federal long-term capital gains are taxed at 0%, 15% or 20%, and which rate you pay depends on where the gain lands once it is stacked on top of your other taxable income. On this calculator's defaults — a $20,000 gain on top of $70,000 of other taxable income, filing single — the whole gain sits above the 2026 0% ceiling of $49,450 and below the 20% floor of $545,500, so it is taxed at 15%: $3,000 of tax and $17,000 kept. The same gain on $40,000 of other income would owe only $1,582.50, because $9,450 of it would fall inside the 0% band.
Sale price minus cost basis.
Before this gain.
Capital gains tax
—
Rate on the gain
—
After-tax gain
—
Note
—

Estimates FEDERAL long-term (held >1 year) capital gains tax using 2026 thresholds (Rev. Proc. 2025-32), stacking the gain on your other income. Short-term gains are taxed as ordinary income instead. Excludes state tax; the 3.8% Net Investment Income Tax may apply at higher incomes. Not tax advice.

No sign-up No ads Runs in your browser — your numbers never leave your device

How long-term capital gains are taxed

Assets held longer than a year get preferential federal rates: 0%, 15%, or 20%, set by your total taxable income with the gain stacked on top. A modest income can keep part of a gain in the 0% band even as the rest is taxed at 15%. Short-term gains (held a year or less) don't get this break — they're taxed like ordinary income.

What the capital gains rate actually depends on

A long-term gain — an asset held more than a year — is not taxed at a single rate you look up in a table. It is stacked on top of your other taxable income and taxed in slices, the same way ordinary brackets work. For 2026 a single filer pays 0% on long-term gains that fall below $49,450 of taxable income, 15% on the part between $49,450 and $545,500, and 20% above that; for a married couple filing jointly the breakpoints are $98,900 and $613,700. Those figures come from the IRS's annual inflation adjustment, Revenue Procedure 2025-32, and they are taxable income thresholds — after the standard deduction — which is why the calculator asks for “other taxable income” rather than salary.

What the number ignores matters as much as what it includes. It is federal only: most states tax capital gains as ordinary income, a few do not tax them at all, and the difference can be larger than the federal rate itself. It assumes the gain is long-term; a sale within a year of purchase is a short-term gain taxed at your ordinary bracket, which for the default income here would be 22%, not 15%. It does not net losses, apply the $3,000 capital-loss allowance, exclude the sale of a main home, or handle depreciation recapture on a rental, and it flags the 3.8% Net Investment Income Tax by a rough threshold rather than computing it.

The worked example, on the calculator's own defaults

Gain $20,000; other taxable income $70,000; single. Stacking puts the gain in the range from $70,000 to $90,000. The 0% band ends at $49,450, which is below $70,000, so none of the gain is tax-free. The 15% band runs to $545,500, which is above $90,000, so the entire $20,000 is taxed at 15%: $3,000. The rate on the gain is 15.0% and the after-tax gain is $20,000 − $3,000 = $17,000. Total income of $90,000 is under the $200,000 single-filer NIIT threshold, so the calculator reports NIIT as unlikely.

Change one input and the stacking shows its teeth. With $40,000 of other taxable income the gain runs from $40,000 to $60,000: the first $9,450 (up to $49,450) is taxed at 0% and the remaining $10,550 at 15%, for $1,582.50 — a blended 7.9% on the gain. The same $20,000 gain for a married couple with $70,000 of taxable income owes nothing at all, because the joint 0% band reaches $98,900. And a single filer with $540,000 of other income pays $3,725: $5,500 of the gain at 15% and $14,500 at 20%.

Decision rules that follow from the mechanism

The mistakes people actually make

Using gross salary as “other income” and overstating the tax; forgetting that the sale price minus purchase price is not the gain when commissions, improvements and reinvested dividends belong in the cost basis; treating inherited assets as if they carried the original owner's basis when they usually step up to the value at death; and assuming a mutual fund or ETF held for years produces only long-term gains, when the fund's own distributions can be short-term. The most expensive one is simpler still: selling in December when waiting three weeks would have moved the gain into a year with less other income.

When a calculator stops being enough

One gain, one year, is a calculator problem. A portfolio is not: lots bought at different prices, partial sales, wash-sale rules, dividends reinvested for a decade and the question of which lot to sell first all need a running record of cost basis, and the answer to “what do I owe” changes with every trade. That is what a spreadsheet like the investment portfolio tracker is for: a log of every lot with its basis, so the gain on any sale is a subtraction rather than an archaeology project. For anything involving a rental, a business sale or an estate, the honest next step is a professional; the figures here are planning estimates, not tax advice.

Quick FAQ

Why does my other income matter?

The rate on your gain depends on where it lands once stacked on your ordinary income. More income pushes more of the gain into higher capital-gains brackets.

What's NIIT?

The 3.8% Net Investment Income Tax applies to investment income above $200k single / $250k joint — an extra layer some high earners owe on top of the capital-gains rate.

Related: income tax calculator · ROI calculator · investment tracker · all free calculators.

Related free calculators

More free taxes & bookkeeping tools — no signup, works on any device.

Browse all 300+ free calculators →

More questions

Is the Capital Gains Tax Calculator free to use?

Yes. The Capital Gains Tax Calculator is completely free, runs in your browser, and never asks for a signup, email, or download. Enter your numbers and the result updates instantly.

How accurate is this calculator?

It uses standard formulas and recalculates the moment you change a value, so the math is exact for the inputs you enter. Treat the result as a reliable planning estimate; for decisions with legal or tax consequences, confirm the figures with a qualified professional.

Does it work on my phone?

Yes. The calculator is mobile-friendly and works on any phone, tablet, or computer — there is no app to install and nothing to save.

Can I add this calculator to my own website?

Yes. Scroll to “Add this free calculator to your site” above and copy the embed snippet to place the live calculator on your blog or website for free.

Last reviewed: September 2026. Free to use, no signup — Capital Gains Tax Calculator by ToolWise Digital.

Add this free calculator to your site

Copy the snippet to embed the live calculator on your blog or website — free for any site. The small “Calculator by ToolWise Digital” credit line keeps it free; you're welcome to remove it, but we appreciate you leaving it.

Tools that do this for you all year

Ready-made Google Sheets & Excel trackers for money, taxes, and small business — each with a free phone version.

Browse the shop →