Capital Gains Estimator
Estimate tax on a sale from adjusted basis, exclusions and losses, at the rates you enter — and see how much improvements and closing costs save you.
Commissions, closing costs and legal fees on both ends — all of it adds to basis.
Work that added value or extended life. Repairs and maintenance do not count.
The rate that applies to you — long-term or short-term, whichever your holding period gives.
Basis is doing the heavy lifting here. Improvements and transaction costs raise it by $79,000 in this scenario, which cuts the taxable gain by the same amount — worth roughly $15,800 in tax. Keep the receipts.
What this calculator does
Sale price, purchase price, transaction costs, improvements and depreciation go in, along with the rates that apply to you. It returns adjusted basis, gross gain, gain after exclusion, taxable gain, tax split into federal, state and surtax, net proceeds, and the effective rate on the gain.
Every rate is an input. This calculator does not know your bracket, your holding period, your filing status or what exclusion you qualify for, and it does not pretend to — those are the facts that make a real sale a professional question rather than an arithmetic one.
Basis is where the money is
The single most valuable line on this page is adjusted basis, because every dollar added to it is a dollar of gain that is never taxed.
It starts as what you paid and gets adjusted for everything since:
Add — capital improvements. Work that adds value, extends useful life, or adapts the property to a new use. A new roof, an addition, a finished basement, a replaced HVAC system, new windows. Not repairs and not maintenance: fixing a leak is a repair, replacing the roof is an improvement, and the line between them is exactly where people lose deductions they were entitled to.
Add — transaction costs. Commissions, transfer taxes, title insurance, legal fees, recording fees, survey costs — on both the purchase and the sale. On real estate these routinely total five to six percent of the price.
Subtract — depreciation. Any depreciation claimed on a rental or business property. See below, because this is the one that ambushes people.
In the calculator’s default scenario, improvements and costs together add $79,000 to basis. At a combined 20 percent rate, that is nearly $16,000 of tax that does not get paid — for keeping records.
Which is the practical takeaway: keep the receipts, for as long as you own the property. A folder of improvement invoices is worth more per hour of effort than almost anything else in personal finance, and the moment you need it is decades after the moment you could have created it.
The costs that surprise people, in both directions
Depreciation recapture. If you claimed depreciation on a rental, it reduced your taxable income in those years — and it reduced your basis by the same amount, so it comes back as gain when you sell. In the US, that recaptured portion is generally taxed at a different and higher rate than the rest of the gain.
Worse, the reduction to basis generally applies to depreciation you were allowed to claim, whether or not you actually claimed it. Skipping the deduction does not avoid the recapture. Enter the figure honestly and get professional advice on the rate, because this calculator applies one rate to the whole gain and a real recapture calculation splits it.
Holding period. Long-term and short-term gains are taxed very differently — preferential rates versus ordinary income. The threshold is a hard line, and a closing date a few weeks earlier or later can move the tax bill by a large amount. If you are near it, check.
Exclusions. Primary residences carry a substantial exclusion in the US subject to ownership and use tests. The calculator takes the exclusion as an input rather than computing it, because eligibility depends on facts about how you lived in the property that no calculator can verify.
Losses. Realised capital losses offset gains, and carryforwards from prior years count. This is why people harvest losses in December — a loss taken against a gain at a 20 percent rate is worth 20 cents on the dollar, and carryforwards do not expire.
Net proceeds versus profit
The headline number people care about is what lands in the bank, and it is not the gain.
Net proceeds here is sale price minus tax. It is not sale price minus tax minus your mortgage payoff, which is the number that determines what you can put down on the next place. For that, the home equity calculator covers the payoff side.
Note also that transaction costs are counted in basis rather than subtracted from proceeds in this model. They reduce the tax, but they also came out of your pocket — so the cash you actually walk away with is lower than the net proceeds line by roughly the amount of those costs.
Why every rate here is an input
Capital gains rates in the US depend on filing status, total income, the type of asset, how long it was held, and whether a surtax applies at your income level. State treatment varies from a full exemption to full ordinary-income taxation.
Hard-coding any of that would mean asserting a legal conclusion about your situation from a handful of inputs, and getting it wrong on a page about a transaction worth hundreds of thousands of dollars. So the rates are yours to supply, from your accountant or your prior return, and the calculator does the arithmetic on them.
What this leaves out
- Rate lookups, deliberately, as above.
- Depreciation recapture at a separate rate. One rate applies to the whole gain here; a real calculation splits the gain.
- Instalment sales, which spread gain across years.
- Like-kind exchanges, which defer gain on investment property entirely.
- Wash sale rules, which disallow losses on substantially identical securities repurchased within a window.
- Estate step-up in basis, which resets basis at death and changes the entire calculus for inherited assets.
- State-specific rules, including states that tax gains as ordinary income and states that do not tax them at all.
For the basis side in more detail — reinvested dividends, splits, per-share basis — see the cost basis calculator.
How this is calculated
adjusted basis = purchase + improvements + transaction costs − depreciation gross gain = sale price − adjusted basis taxable gain = gain − exclusion − losses available tax = taxable gain × (gains rate + state rate + surtax)
Frequently asked questions
- How do I calculate capital gains on a property sale?
- Start with the sale price and subtract your adjusted basis — what you paid, plus capital improvements, plus transaction costs on both ends, minus any depreciation you claimed. Then subtract any exclusion you qualify for and any capital losses available to offset. What remains is the taxable gain, and your rate applies to that.
- What is adjusted basis?
- Your original cost adjusted for everything that happened since. Capital improvements raise it, commissions and closing costs raise it, and depreciation you claimed lowers it. Basis is the single most valuable number in a property sale because every dollar of it is a dollar not taxed — which is why keeping improvement receipts for decades genuinely pays.
- Do closing costs reduce capital gains?
- Yes. Commissions, transfer taxes, title fees and legal costs on both the purchase and the sale generally adjust basis or reduce the amount realised, and either way they reduce the taxable gain. On a property sale these routinely total five to six percent of the price, which at a combined twenty percent rate is real money.
- What is the difference between short-term and long-term capital gains?
- Holding period. Assets held beyond the long-term threshold are taxed at preferential rates; assets sold sooner are generally taxed as ordinary income at your marginal rate. The gap is large enough that a sale date a few weeks either side of the threshold can change the tax bill substantially, which is worth checking before you sign anything.
- What is depreciation recapture?
- Depreciation claimed on a rental property reduces your basis, so it increases the gain when you sell — and the portion attributable to that depreciation is generally taxed at a different, higher rate than the rest of the gain. Owners who claimed depreciation for years are frequently surprised by this, and it is the main reason a rental sale needs professional input.