Capital Gains Tax Calculator
Free capital gains tax calculator for the US and Canada, 2026 rates. See exactly which tax brackets your gain fills — 0/15/20% LTCG stacking and NIIT in the US, the 50% inclusion rate in Canada — with sources for every rate.
Estimate only, not tax advice. This is federal (plus, for Canada, provincial) tax on the gain itself — it excludes US state tax, AMT, loss carryforwards, and every province-specific quirk noted below. See the full disclaimer under "What this calculator doesn't model."
How US capital gains tax actually works: short-term, long-term, and 0/15/20% stacking
The US taxes capital gains differently depending on how long you held the asset before selling.Short-term gains — from an asset held one year or less — are taxed as ordinary income, stacked on top of your wages and other income and running through the same 10–37% brackets as a paycheck. Long-term gains — held more than one year — get a separate, preferential set of federal brackets: 0%, 15%, or 20%, depending on your total taxable income. That one-year threshold is the single most consequential date in US capital gains planning: selling one day before versus one day after it can change your tax bill by thousands of dollars on an identical gain, with nothing else about the transaction different.
The long-term brackets don't apply to the gain in isolation — they apply to your totaltaxable income, with the gain conceptually stacked on top of everything else you earned. If your ordinary income already fills the 0% band on its own, the bottom slice of your gain is taxed at 0%; once the stack crosses into the 15% band, that portion of the gain is taxed at 15%; and so on into the 20% band at the top. This calculator implements that stacking exactly: it computes the tax as if your ordinary income plus the entire gain were taxed under the long-term brackets, then subtracts the tax on your ordinary income alone — the difference is precisely the tax on the gain, split across however many bands it crosses. The band chart above visualizes that split for your own numbers, so you can see directly whether your gain lands entirely in one bracket or straddles two or three.
A concrete example: a single filer with $40,000 of other taxable income who realizes a $20,000 long-term gain, for tax year 2026. The 0% band for a single filer runs up to $49,450 of total taxable income, so the first $9,450 of the stacked gain ($49,450 − $40,000) falls at 0%. The remaining $10,550 falls in the 15% band, owing $1,582.50. Total federal tax on that $20,000 gain: $1,582.50 — an effective rate on the full gain of about 7.9%, well under the 15% headline rate most people would guess, because part of the gain still fit inside the 0% band. Small changes in taxable income near a band edge can swing the effective rate noticeably; that's exactly the kind of thing worth checking with your own numbers above rather than assuming a flat percentage.
Source: IRS Rev. Proc. 2025-32 sets the 2026 long-term capital gains brackets; see also the IRS's 2026 tax inflation adjustments releasefor the short-term ordinary brackets used above.
Net Investment Income Tax (NIIT): the extra 3.8%
On top of ordinary federal capital gains tax, higher earners in the US owe an additional 3.8% Net Investment Income Tax under IRC §1411 on some or all of their investment income, including capital gains, interest, dividends, and rental income. NIIT applies to the lesser of two numbers: your net investment income for the year, or the amount by which your modified adjusted gross income (MAGI) exceeds a threshold — $200,000 for single filers, $250,000 for married filing jointly, for tax year 2026. Unlike the ordinary brackets, these thresholds are fixed by statute and are not adjusted for inflation, so they haven't moved in years and won't move next year either.
This calculator applies NIIT exactly as the statute does: it computes3.8% × min(your capital gain, max(0, taxable income + gain − threshold)). In plain terms, if your income including the gain doesn't cross the threshold at all, NIIT is $0 regardless of how large the gain is; once you're over the threshold, NIIT applies to whichever is smaller — the gain itself, or just the slice of income that's actually over the threshold. NIIT is calculated independently of the short-term/long-term distinction and is added on top of whichever ordinary or long-term rate already applies — it's a surtax, not a replacement rate. Canada has no direct equivalent tax.
Source: IRS Topic no. 559, Net Investment Income Tax.
How Canadian capital gains tax actually works: the 50% inclusion rate
Canada takes a completely different approach: instead of a separate preferential bracket schedule, only a fraction of the capital gain — the "inclusion rate" — is added to your taxable income at all, and that included portion is then taxed at your regular marginal federal-plus-provincial rate, the same rate that applies to an extra dollar of salary. For 2026, that inclusion rate is 50% (one half), after the federal government's 2024 proposal to raise it to two-thirds above a $250,000 annual threshold was formally cancelled in March 2025 — the rate that remains in effect is the long-standing 50%, with no increase currently proposed.
Concretely: a $10,000 capital gain adds only $5,000 to your taxable income, not $10,000. That $5,000 then stacks on top of your other income and is taxed at whatever combined federal + provincial bracket(s) it fills — exactly the same stacking-and-subtracting method described above for the US long-term brackets, just applied to the taxable half of the gain instead of the whole thing. Worked example, Ontario, 2026: $80,000 of other income, a $50,000 capital gain (proceeds $130,000, cost $80,000). The taxable amount is $25,000 (50% inclusion). Stacking that $25,000 on top of $80,000 across the combined federal + Ontario brackets produces roughly $7,558 of combined tax — an effective rate on the full $50,000 gain of about 15.1%, even though the marginal bracket the taxable half fell into runs well above 30% combined. That gap between the marginal bracket rate and the effective rate on the whole gain is the entire point of the inclusion rate, and it's exactly why "capital gains tax is 50% in Canada" is a myth worth retiring — see the FAQ below.
Two caveats this calculator inherits directly from its source data and does not attempt to correct for. Quebec: the Quebec estimate above uses Quebec's own provincial brackets only and ignores the federal abatement — Quebec residents receive a 16.5% abatement of federal tax that a fully precise estimate would need to net against federal tax owing, which this calculator does not do. Ontario and Prince Edward Island: both provinces levy an additional provincial surtax once basic provincial tax exceeds a threshold — Ontario's two-tier surtax alone can push its effective top marginal provincial rate to roughly 20.5%, well above the 13.16% top base-bracket rate this calculator uses. That surtax is not modeled here, so ON and PE estimates understate total tax for higher-income filers specifically. Every other province's brackets are used as published, with no equivalent adjustment needed.
Source: Prime Minister's Office, March 21, 2025 (inclusion rate increase cancelled);CRA current-year federal and provincial tax ratesfor the 2026 bracket tables (Quebec via Revenu Québec).
Selling stocks vs. selling property: the principal-residence and primary-home exceptions
Everything above describes the default rules, which apply the same way whether you sold shares, a fund, or real estate. Both countries carve out a major exception specifically for the home you actually live in.
Canada — principal residence exemption. If a property qualified as your principal residence for every year you owned it, the capital gain on its sale is generally fully exempt from tax — no inclusion rate, no tax at all, though you still must report basic sale details (date acquired, proceeds, description) on Schedule 3 to claim the exemption. A property only partially designated as your principal residence — say, you rented it out for several of the years you owned it — gets a proportional exemption based on the fraction of ownership years it qualified, with the remaining gain taxed under the ordinary rules above. A second home, cottage, or investment property that was never your principal residence gets none of this and is taxed exactly like the stock-sale examples in this article.
United States — Section 121 exclusion. Sell your main home and you can generally exclude up to $250,000 of the gain (single filers) or $500,000 (married filing jointly) from federal tax entirely, provided you meet the ownership test (owned the home at least 2 of the last 5 years) and the use test (lived in it as your main home at least 2 of the last 5 years). These dollar amounts are fixed by statute, not inflation-indexed, and generally can't be claimed on more than one home sale within a two-year span. A rental property or a second home you didn't primarily live in doesn't qualify — it's taxed under the ordinary short/long-term rules described above, exactly like the stock examples this calculator was built around.
This calculator's math is identical whether you plug in a stock sale or a property sale that doesn't qualify for either exception above — it doesn't know or care what the underlying asset is, only the cost, proceeds, and your income. If your sale might qualify for the principal-residence exemption or Section 121, subtract the exempt/excluded amount from the gain yourself before entering it, or consult a tax professional to confirm eligibility first.
Sources: CRA Income Tax Folio S1-F3-C2, Principal Residence;IRS Topic no. 701, Sale of Your Home (Section 121, the $250,000/$500,000 exclusion, and the ownership/use tests).
US stocks in a Canadian account
A common cross-border question: does it matter, for capital gains purposes, that the stock you're selling is American while you're a Canadian resident? For most Canadian residents who are not US citizens or green card holders, no — the IRS generally does not tax a non-US-person's gain on selling US-listed shares at all, regardless of which account holds them. The two wrinkles that actually matter are different from what people usually expect. First, currency conversion: your adjusted cost base and your proceeds must both be converted to Canadian dollars at the exchange rate in effect on their respective transaction dates before the CRA will let you compute the gain — which means a stock that didn't move a cent in USD terms can still show a capital gain or loss in CAD terms purely from the Canadian dollar moving against the US dollar between your purchase and sale dates. That FX effect is real, taxable, and easy to miss if you only look at the US-dollar price. Second, account type: gains inside a TFSA are tax-free in Canada exactly as they would be for a Canadian stock — the TFSA/US tax-treaty wrinkle that trips people up is specific to dividends(a 15% US withholding tax applies to US dividends paid into a TFSA, because the IRS doesn't recognize a TFSA as a retirement account under the treaty the way it recognizes an RRSP), not to capital gains on sale, which this calculator estimates.
The exception that matters most: if you are a US citizen or green card holder living in Canada, US tax rules generally still apply to you regardless of residency, and Canadian-domiciled mutual funds or ETFs can trigger the notoriously punitive US PFIC (Passive Foreign Investment Company) regime. That combination of citizenship-based US taxation and PFIC exposure is a genuinely specialized area this calculator does not model at all — if it might apply to you, that's a conversation for a cross-border tax specialist, not a spreadsheet.
Every default, and why it's set where it is
- US: single, $90,000 taxable income, $10,000 cost, $25,000 proceeds, held >1 year.A $15,000 long-term gain landing on a moderate income, deliberately positioned to fall mostly in the 15% long-term band rather than the 0% band — a more representative scenario than a number engineered to look small.
- CA: Ontario, C$80,000 other income, C$20,000 cost, C$30,000 proceeds. A C$10,000 gain on a similar moderate-income profile, using Canada's most populous province as the default since it's the single most common province among this site's visitors — swap the province select to your own immediately.
- Held more than 1 year — checked by default. Long-term treatment is both the more common real-world case for buy-and-hold investors and the scenario this site is built around; uncheck it to see exactly how much more a short-term sale of the same size would cost.
What this calculator doesn't model
This is an estimate, not tax advice, and not a substitute for a tax professional or tax software that has your complete return. Specifically excluded from every number above: US state and local capital gains tax (which varies enormously — some states tax capital gains as ordinary income at rates over 10%, others levy none); the Alternative Minimum Tax; capital loss carryforwards, carrybacks, or the US's $3,000 annual net-loss deduction cap; Canadian capital gains or loss carryovers and the lifetime capital gains exemption for qualified small business shares and farm/fishing property; the Ontario and PEI provincial surtaxes and the Quebec federal abatement noted above; any state, provincial, or territorial equivalent of NIIT beyond the federal 3.8%; foreign tax credits; cost-basis adjustments for reinvested distributions, wash sales, or inherited/gifted-asset basis rules; and any transaction, advisory, or brokerage fees. Every output is a same-year, current- rate, single-transaction estimate meant for planning and comparison, not a filing-ready number. Verify any real transaction with a licensed accountant or tax preparer in your jurisdiction before acting on it.
FAQ
How much tax will I pay on $X of capital gains?
There's no single answer to this without knowing your other income, filing status/province, and (in the US) how long you held the asset — capital gains are stacked on top of your other income and taxed at whatever bracket(s) that stack fills, not at one flat percentage. A $50,000 gain sitting on top of $30,000 of other income can land almost entirely in a 0% or low bracket; the same $50,000 gain sitting on top of $600,000 of other income lands almost entirely in the top bracket. That's exactly what the calculator above computes for your real numbers — enter your income, province or filing status, and the sale details, and the tiles and band chart show precisely which brackets your gain fills and what it costs.
Is capital gains tax 50% in Canada?
No — this is one of the most common misreadings of the Canadian system. 50% is the inclusion rate, meaning only half of a capital gain is added to your taxable income; it is not a tax rate. The other half is never taxed at all. What you actually pay is your marginal tax rate applied to that included half. Even someone in Canada's highest combined federal + provincial bracket (roughly the low-to-mid 50s of a percent in the highest-taxed provinces) pays at most about half of that rate — call it a ceiling somewhere in the mid-20s of a percent — on the full capital gain, not 50% of the gain itself. See the "How the 50% inclusion rate works" section above for the exact arithmetic.
How do I avoid capital gains tax?
You mostly can't avoid it outright on a taxable sale, but several legitimate mechanisms reduce or eliminate it. Holding investments inside a registered account — a TFSA, RRSP, or FHSA in Canada; a Roth IRA, traditional IRA, or 401(k)/403(b) in the US — removes the sale from capital-gains treatment entirely (TFSA/Roth: never taxed; RRSP/traditional IRA: taxed later as ordinary income on withdrawal, not as a capital gain). Selling your principal residence (Canada) or primary home under the Section 121 exclusion (US) can eliminate some or all of the gain — see the FAQ below. Realizing capital losses in the same year (or, in the US, carrying them forward) to offset gains — "tax-loss harvesting" — reduces the net taxable amount. Donating appreciated securities directly to a registered charity, rather than selling and donating cash, avoids realizing the gain in both countries under specific rules. None of these are modeled by this calculator, which estimates the tax on a straightforward taxable sale only — talk to a tax professional before relying on any of them for a specific transaction.
What's NIIT?
The Net Investment Income Tax is a US-only 3.8% federal surtax on investment income — including capital gains — for higher earners, on top of ordinary capital gains tax. It applies to the lesser of your net investment income or the amount by which your modified adjusted gross income (MAGI) exceeds a threshold ($200,000 single / $250,000 married filing jointly for tax year 2026 — these thresholds are fixed by statute and not inflation-indexed). It has no Canadian equivalent. See the "Net Investment Income Tax" section above for the full mechanics and the calculator's exact formula.
What's the difference between short-term and long-term capital gains?
In the US, this distinction is central: hold an asset for one year or less and the gain is "short-term," taxed as ordinary income at rates up to 37%; hold it for more than one year and the gain is "long-term," taxed at the much lower 0/15/20% preferential rates. The calculator's "held more than 1 year" toggle switches between these two bracket tables. Canada makes no such distinction for the capital-gains inclusion rate — a gain realized after one day or ten years is included in taxable income at the same 50% rate — though frequent, pattern-of-trading activity can sometimes cause the CRA to recharacterize gains as fully taxable business income instead of capital gains, which is a different question entirely from holding period.
Do I pay capital gains tax when I sell my house?
Usually not on your primary home, in either country, up to a limit — but you generally do on investment or rental property, with no such exclusion. In Canada, a property that qualifies as your principal residence for every year you owned it is normally fully exempt from capital gains tax on sale. In the US, Section 121 lets you exclude up to $250,000 of gain (single) or $500,000 (married filing jointly) on the sale of your main home, provided you meet ownership and use tests (generally: owned and lived in it as your main home for at least 2 of the last 5 years). Neither exemption applies to a second home, a rental property, or a property you didn't primarily live in — those are taxed under the ordinary rules this calculator estimates. See the "Selling stocks vs. selling property" section above for sourcing and the fine print.
Documented, not advised. This calculator is for education; verify decisions with a licensed professional.