Skip to content
CalculatorZilo Logo
  • Home
  • CalculatorsExpand
    • Browse all calculators
    • Education
    • Real Estate
    • Chemistry
  • Finance
  • Math
  • Health & Fitness
  • Science
  • About
  • Contact
CalculatorZilo Logo
Home / Gain On Sale Calculator
Tax Calculators

Gain On Sale Calculator

Published onSeptember 30, 2025 Updated onOctober 27, 2026 1:27 pm

Selling an asset raises two questions: what was my gain, and what will I owe on it? The first is arithmetic. The second depends on your tax rules, and on whether you mean the tax view or the accounting view. This calculator answers both: a capital gains tax estimate from your sale price, cost basis, and tax rate, and a book gain calculation that works from purchase price and accumulated depreciation, the way the sale will appear in business accounts.

Gain on Sale Calculator
Your profit on an asset sale, and an estimate of the tax on it.
$
$

What you paid, plus capital improvements, minus depreciation claimed. Selling costs can be added here too.

%

Your applicable rate. Common reference points: US federal long-term 0/15/20%, UK residential 18/24% after the annual allowance. Exclusions (like a primary-home exclusion) reduce the taxable gain first.

$
$

Total depreciation claimed to date. For land, enter 0: land is not depreciable.

$

Quick Answer

Sell for $550,000 with a $300,000 cost basis and the gain is $250,000; at a 15% capital gains rate the estimated tax is $37,500 and net proceeds are $512,500. On the accounting side, equipment bought for $50,000 and depreciated by $20,000 has a book value of $30,000, so selling it for $40,000 books a gain on sale of $10,000 (33.33%). Both examples are pre-filled in the calculator, one per tab.

Key takeaways

  • Gain is always sale price minus a basis. The two tabs differ only in which basis: adjusted cost basis for tax, book value for accounts.
  • Depreciation cuts both ways: every dollar of depreciation claimed lowers your basis and raises the gain when you sell.
  • A loss is not taxed. The tax tab floors the taxable gain at zero, while the book tab still reports the loss in dollars and percent.
  • The tool applies the single rate you enter. Exclusions, allowances, brackets, and recapture are yours to fold in first, which is why the result is an estimate, not a filing.
On this page
  • Quick Answer
  • How to use the Gain on Sale Calculator
  • The two formulas
  • Worked examples, with the split shown
  • Cost basis: the number that decides everything
  • Short-term, long-term, and which rate to enter
  • Depreciation, book value, and recapture
  • When the sale is a loss
  • What competing calculators miss
  • Frequently asked questions
  • Add This Calculator to Your Website
  • References

How to use the Gain on Sale Calculator

Pick the tab that matches your question: the tax you might owe, or the gain your accounts will show. Each tab has its own Calculate button and its own result box, and results stay hidden until you calculate.

  1. Capital gains tax estimate: enter the sale price, your adjusted cost basis, and the tax rate that applies to you, then calculate. You get the gain (or loss), the estimated tax, and net proceeds after tax. A blank basis or rate field counts as zero, so a quick gain check needs only the two prices.
  2. Book gain on asset sale: enter the purchase price, accumulated depreciation, and sale price from the asset register, choose the asset type for the record, and calculate. You get book value, the gain or loss in dollars and as a percentage of book value, and a gain, loss, or break-even verdict badge.
  3. Reset restores both worked examples if you want to start over, and Copy and Share sit inside each result box.

The two formulas

Both modes are one subtraction each. What changes is the basis definition, and that difference is the whole reason the page has two tabs.

Capital gain = Sale price − Adjusted cost basis, where the basis is the purchase price plus capital improvements minus depreciation claimed. Estimated tax = Taxable gain × Tax rate, with the taxable gain floored at zero so a loss never produces a negative tax. Net proceeds = Sale price − Estimated tax. These are the definitions the IRS works from in IRS Topic No. 409, Capital Gains and Losses: a capital asset sold for more than its basis produces a capital gain, and held for more than one year that gain is long-term.

Book value = Purchase price − Accumulated depreciation. Gain or loss on sale = Sale price − Book value. A positive result is a gain on sale, a negative result a loss, and the percentage is the gain or loss divided by book value. Note the asymmetry the two tabs create: the same depreciation that produces a book gain when an asset sells above its written-down value also enlarges the taxable gain, because it shrank the tax basis too.

Tax view: capital gains estimate

  • Answers: what is my gain, and roughly what tax follows?
  • Basis: what you paid, plus improvements, minus depreciation.
  • Best for: home sales, investments, one-off asset disposals, planning a sale before year end.
  • Watch out for: exclusions, allowances, and recapture sit outside the tool and change the taxable figure.

Book view: gain on asset sale

  • Answers: what gain or loss hits the income statement?
  • Basis: book value, the purchase price written down by depreciation.
  • Best for: selling plant, vehicles, and equipment off the fixed-asset register.
  • Watch out for: a fully depreciated asset shows 0.00% even on a real gain, because the percentage divides by a zero book value.

Worked examples, with the split shown

Tax estimate. You sell for $550,000 with a $300,000 cost basis at a 15% rate: gain = $250,000.00, estimated tax = $37,500.00, net proceeds = $512,500.00. The bars below scale each figure to the $550,000 sale price, which is the fastest way to see where the money actually goes.

Cost basis$300,000
Gain$250,000
Tax at 15%$37,500
Net proceeds$512,500

Book gain. Equipment bought for $50,000 with $20,000 of accumulated depreciation sells for $40,000: book value = $30,000, gain = $10,000.00 (33.33%), a gain on sale even though the asset sold for less than it cost. That last point surprises people: the book comparison is against the written-down value, not the sticker price. Both examples are the pre-filled values in the calculator.

Cost basis: the number that decides everything

Every dollar of basis is a dollar of gain you are not taxed on, so basis errors are the most expensive mistakes in this calculation. Basis starts at the purchase price, rises with capital improvements (a remodel, a new roof, an addition), and falls with depreciation claimed. It does not move for routine repairs. The IRS sets out what counts in IRS Publication 551, Basis of Assets, including the stepped-up basis that inherited property usually receives. If your basis has several moving parts, the asset adjusted basis calculator builds it line by line before you bring the total here. Selling costs such as agent commissions are the other lever: this tool's basis field accepts them folded in, which reduces the gain the same way an amount-realized adjustment would.

Short-term, long-term, and which rate to enter

How long you held the asset usually decides the rate. The tool takes one rate, so use this table to pick the right one before you calculate.

SituationRate to enterNotes
US, held over 1 year (long-term)0%, 15%, or 20%Depends on taxable income; a 3.8% net investment income tax can apply on top at higher incomes
US, held 1 year or less (short-term)Your ordinary income rateTaxed like salary, at your marginal bracket rate
US primary homeRate on the gain above the exclusionUp to $250,000 of gain excluded ($500,000 married filing jointly) if ownership and use tests are met; subtract the exclusion from the gain first
UK residential property18% or 24%After the £3,000 annual exempt amount; the main home is normally exempt

The US figures follow IRS Publication 523, Selling Your Home for the exclusion and IRS Topic No. 559 for the 3.8% net investment income tax; the UK figures follow GOV.UK's guidance on tax when you sell property and its capital gains tax rates page. Rates and thresholds change, so confirm the current ones for your situation with a tax professional before you rely on the estimate.

Depreciation, book value, and recapture

Depreciation is a loan from your future self: the deductions reduced your tax while you held the asset, and the sale settles the account. In the book view, accumulated depreciation sets the book value the sale is compared against. In the tax view, the same depreciation reduced your basis, and for business or rental property the IRS can tax the depreciation portion of the gain as ordinary income, called depreciation recapture, at up to 25% for real property under the rules in IRS Publication 544, Sales and Other Dispositions of Assets. This calculator does not split the gain into recapture and capital portions; if depreciation is a large share of your gain, run the plain estimate here, then have the split checked before filing. If you still need the accumulated figure itself, the depreciation expense calculator works it out year by year, and IRS Publication 946 is the reference for how the deductions were computed in the first place.

When the sale is a loss

Selling below basis produces a capital loss in the tax tab (tax of $0.00, because losses are not taxed) and a loss on sale in the book tab. The two losses are not wasted paper: capital losses generally offset capital gains, and US filers can deduct up to $3,000 of net capital loss against other income per year and carry the rest forward, as IRS Topic No. 409 sets out. Reporting runs through Form 8949 and its instructions, summarized on Schedule D. If you are harvesting losses deliberately, the capital loss deduction calculator sizes the deduction year by year. One boundary of this page: it keeps the gain scope only. Its mirror, the loss on sale page, covers the loss-first view; here, losses appear as the negative case of the same formulas, which is all most sellers need.

What competing calculators miss

The gain on sale keyword splits into share-trading tools, single-country tax engines, and accounting explainers, and each camp stops one question short:

  • AIOnlineCalculator's capital gains tool: built around share quantity (buy price times shares), so a house or a machine has to be forced into a per-unit shape. Its "net" is the gain after tax, not your proceeds, which understates what lands in your account by the entire basis.
  • AJDesigner's gain on sale page: the richest scenario writing in the set, including depreciation recapture and 1031 exchanges, but it is worked examples only: there is no tax estimate and no book percentage to take away for your own asset.
  • MyCalculator's Australian CGT tool: competent and completely jurisdiction-locked, with the Australian 50% discount baked into its headline formula, a formula that is simply wrong outside that one rule set.
  • TheMoneyPocket and Grace-Cap: deep US bracket engines with filing status, state tax, and NIIT. Powerful if you are a US filer with all that data at hand, unusable for a UK seller or a bookkeeper who only needs the accounting gain.
  • LegalClarity and the Sage community answer: clear explainers of amount realized and carrying value with no calculator at all. You still do the arithmetic yourself.
  • The gap this page fills: both views in one place, a jurisdiction-neutral tax estimate where you supply the rate, plus the full book-gain calculation with depreciation, asset type, and a gain, loss, or break-even verdict badge, with copy and share on every result.

Frequently asked questions

The profit when you sell an asset for more than its cost basis: sale price minus what you paid, adjusted for improvements, depreciation, and selling costs.

Your original purchase price plus capital improvements, minus depreciation claimed. Selling costs such as commissions can also reduce the gain.

Usually yes, as a capital gain, unless an exclusion applies (for example, a primary-home exclusion) or the asset is in a tax-advantaged account.

Short-term gains (assets held a year or less in the US) are generally taxed at higher ordinary-income rates; long-term gains get preferential lower rates.

Yes, in both modes in this calculator. In the tax estimate, depreciation claimed reduces your adjusted basis, which increases the taxable gain when you sell. In the book view, accumulated depreciation reduces book value, so the same sale price produces a larger gain on sale. Part of the gain on business property can also be taxed as depreciation recapture rather than as a capital gain.

Yes: selling below your basis produces a loss on sale. Capital losses can often offset gains for tax purposes.

Capital improvements (remodels, new roofs, additions) increase your basis and reduce the gain. Repairs generally do not.

Inherited assets often receive a stepped-up basis to fair market value at death, which can sharply reduce the taxable gain.

Because the percentage divides the gain by book value, and a fully depreciated asset has a book value of zero. The calculator reports 0.00% instead of dividing by zero, so read the dollar figure as the real answer in that case: an asset bought for $20,000, depreciated to $0, and sold for $15,000 shows a gain of $15,000.00 at 0.00%.

No. You enter the rate that applies to you and the tool multiplies the taxable gain by it. It does not apply exclusions, allowances, brackets, or recapture rules on its own, so reduce the gain for any exclusion first (or fold the adjustment into the basis) and confirm the final figure with a tax professional.

Add This Calculator to Your Website

Embed this calculator on your own site with the code below. Pick a size to preview it live, then copy the code.

Powered by Calculator Zilo

References

  1. Internal Revenue Service. Topic No. 409, Capital Gains and Losses. Accessed October 21, 2026.
  2. Internal Revenue Service. Publication 551, Basis of Assets. Accessed October 21, 2026.
  3. Internal Revenue Service. Publication 523, Selling Your Home. Accessed October 21, 2026.
  4. Internal Revenue Service. Publication 544, Sales and Other Dispositions of Assets. Accessed October 21, 2026.
  5. Internal Revenue Service. Publication 946, How To Depreciate Property. Accessed October 21, 2026.
  6. Internal Revenue Service. Topic No. 703, Basis of Assets. Accessed October 21, 2026.
  7. Internal Revenue Service. Topic No. 559, Net Investment Income Tax. Accessed October 21, 2026.
  8. Internal Revenue Service. Instructions for Form 8949, Sales and Other Dispositions of Capital Assets. Accessed October 21, 2026.
  9. GOV.UK. Tax when you sell property. Accessed October 21, 2026.
  10. GOV.UK. Capital Gains Tax rates and allowances. Accessed October 21, 2026.

Related calculators

Tax CalculatorsCar Loan Interest Deduction CalculatorIf you bought an electric vehicle expecting a federal tax credit, the rules changed in 2025.Tax CalculatorsAGI Calculator: Find Your Adjusted Gross IncomeAdjusted gross income is the number your whole tax return hangs on.Tax CalculatorsBonus Take Home Pay Calculator: Your Net BonusYou were promised a $10,000 bonus and the deposit says $6,535. Nothing went wrong.Tax Calculators1040 CalculatorForm 1040 is the tax return almost every US worker files, yet the number at the bottom is a mystery to most filers until software spits it out.Tax CalculatorsFiling Deadline CalculatorPick a tax year and a filing type and this calculator returns your federal filing deadline, the automatic extension deadline beside it, and a live countdown of the days left from today.Tax CalculatorsAdjusted Income CalculatorAdjusted income is the number between what you earn and what you are taxed on: your gross income, minus a specific set of adjustments that the tax code lets you take before anything else.

We use cookies to analyze traffic. You can accept or decline cookies below. Learn more

calculatorzilo

CalculatorZilo

Free calculators for everyday life. No signup, no cost, just answers.

Categories

Finance Math Health & Fitness Education Science Real Estate Chemistry Browse all calculators

Popular tools

Mortgage Payment Calculator BMI Walking Calculator Salary Per Minute Calculator Percentage Off Calculator

Company

About Us Contact Us Privacy Policy Terms and Conditions
Disclaimer Cookie Policy DMCA Policy Affiliate Disclosure FAQ Accessibility Statement

© 2026 CalculatorZilo • Free calculators for everyone

  • Home
  • Calculators
    • Browse all calculators
    • Education
    • Real Estate
    • Chemistry
  • Finance
  • Math
  • Health & Fitness
  • Science
  • About
  • Contact
Search