Skip to content
Real estate

Gain on Sale Calculator

Calculate the gain or loss from selling an asset using the gain on sale formula with support for adjusted basis, depreciation recapture, and capital gains analysis.

Capital gain inputs

$
$

Gain on sale

$90,000.00

Gain on sale calculation details

Open to see how the selected variable is derived from your inputs.

  1. Identify formula

    Gain on Sale=Sale PriceAdjusted Basis\text{Gain on Sale} = \text{Sale Price} - \text{Adjusted Basis}

    Gain on sale equals sale price minus adjusted basis.

  2. Substitute values

    SP=400,000AB=310,000\text{SP} = 400,000 \quad \text{AB} = 310,000

    Sale price = $400,000.00, adjusted basis = $310,000.00.

  3. Calculate result

    400,000310,000=90,000400,000 - 310,000 = 90,000

    $400,000.00 - $310,000.00 = $90,000.00.

Report tool

How the gain on sale calculator works

Capital gain on a property sale equals the sale price minus your adjusted basis. This calculator solves for gain or loss, required sale price, or adjusted basis. It is a pre-tax planning tool and does not apply federal brackets, exclusions, or depreciation recapture. All math runs in your browser.

Adjusted basis reflects purchase price, capital improvements, and accumulated depreciation. To track book depreciation, use the accumulated depreciation calculator. For broader capital gain estimates on investments, open the capital gains calculator. If you are flipping homes, pair this with the after repair value calculator to model resale profit before sale.

Gain on sale formula

Gain on Sale=Sale PriceAdjusted Basis\text{Gain on Sale} = \text{Sale Price} - \text{Adjusted Basis}

Adjusted basis is typically original cost plus improvements minus accumulated depreciation. A negative result is a capital loss, subject to IRS limits and holding-period rules.

Worked example: $400,000 sale, $310,000 adjusted basis

  1. Sale price: $400,000
  2. Adjusted basis: $310,000
  3. Gain on sale: $400,000 - $310,000 = $90,000

Tax owed depends on holding period, income, and whether Section 121 or 1031 rules apply. Consult a tax professional before filing.

Frequently asked questions

What is adjusted basis?
Adjusted basis is your tax cost in the asset after capital improvements and accumulated depreciation. It is the amount subtracted from sale price to find gain or loss.
Does this calculator include depreciation recapture?
No. Depreciation recapture can tax part of the gain at ordinary rates. Enter an adjusted basis that already reflects depreciation taken.
Can I solve for the sale price I need to hit a target gain?
Yes. Select solve for sale price, then enter your target gain and adjusted basis. The tool adds the two amounts.
What if I sell at a loss?
When sale price is below adjusted basis, the result is a capital loss. Deductibility depends on whether the asset was held for personal or investment use.
Are the results stored?
No. Inputs update the page URL for sharing, but nothing is saved on a server.

Resources and references

The formulas and methods in this calculator were checked against these independent sources.