Work out the capital gains tax a 1031 exchange can defer — federal tax, depreciation recapture, the 3.8% net investment income tax and state tax — plus your 45-day and 180-day deadlines, your boot, and the minimum replacement property you need to defer everything.
Take a married couple selling a rental for $1,000,000 with a $400,000 adjusted basis, $60,000 of selling costs and $150,000 of depreciation taken. The gain is $540,000. Selling outright, the federal tax is about $88,328, the 3.8% net investment income tax adds $14,820, and California at 13.3% adds $71,820 — $174,968 in total, about 32% of the gain. A qualifying 1031 exchange defers all of it, as long as the replacement property costs at least $940,000, the replacement mortgage is at least $500,000, and both deadlines are met. Run your own numbers in the calculator below.
The exchange does not erase the tax — it postpones it. The deferred gain carries into the replacement property’s basis, so the tax comes due when that property is eventually sold without an exchange (or disappears at death, when the basis steps up). What the exchange buys is time and compounding: the full $440,000 of sale cash stays invested instead of $265,032 after tax.
Enter your sale, your basis and your replacement property. The calculator uses the 2026 federal brackets (IRS Revenue Procedure 2025-32), the Schedule D stacking method for depreciation recapture, the 3.8% net investment income tax and your state’s top marginal rate as an estimate. It is a planning estimate, not a tax return calculation.
The state rate is the top marginal rate for 2026. Most states tax capital gains as ordinary income through graduated brackets, so your actual state tax is usually lower than this estimate — change the rate if you know your own effective rate. Washington’s 7% capital gains tax exempts real estate, so Washington is 0% here.
Selling costs come out of your sale proceeds, so a trade-up usually needs a slightly larger replacement mortgage (or some cash added) to close. In the default example the $60,000 of selling costs is covered by a $560,000 replacement mortgage instead of $500,000.
Your sale
Tax if you sell outright
Your exchange
To defer everything
Your deadlines
| How the federal tax is built | Amount | Tax |
|---|---|---|
| Gain taxed at 0% (room left in the 0% bracket) | — | $0 |
| Gain taxed at 15% | — | — |
| Gain taxed at 20% | — | — |
| Recapture taxed at up to 25% (Schedule D worksheet) | — | — |
| Ordinary income + recapture taxed at ordinary rates | — | — |
| Federal tax on the sale (sum of the pieces above, less tax on your other income alone) | — |
How to read this: your other taxable income fills the lowest brackets first, then the gain stacks on top of it. The depreciation (recapture) portion is taxed at ordinary rates up to the top of the 24% bracket and at 25% above that — 25% is a ceiling, not a flat rate. See how the tax is figured.
Planning estimate only. The federal figures use the 2026 brackets in IRS Revenue Procedure 2025-32 and the Schedule D Tax Worksheet method. Your actual tax depends on your full return, your state’s brackets, losses and carryovers, and whether the exchange qualifies. The calculator assumes the property was held more than one year, the gain is long-term, and the sale is not your primary residence.
Four numbers drive everything: the gain, the recapture, the brackets your gain lands in, and the boot. The calculator follows the IRS Schedule D Tax Worksheet, not the shortcut of multiplying the whole gain by one rate.
Selling costs are the costs of the sale itself — broker commission, title, escrow, recording, transfer tax. They reduce the amount realized, which reduces the gain. Your adjusted basis is what you paid, plus improvements, less depreciation taken.
Depreciation you took comes back as unrecaptured Section 1250 gain, capped at the smaller of your depreciation or your total gain. In the $1M example, $150,000 of the $540,000 gain is recapture and $390,000 is the remaining gain. The two pieces are taxed differently, which is why the calculator keeps them separate.
Long-term gain is taxed at 0%, 15% or 20% depending on where it sits on top of your total taxable income — your other taxable income fills the brackets first, then the gain stacks on top:
| Filing status | 0% up to | 15% up to | 20% above |
|---|---|---|---|
| Single | $49,450 | $545,500 | $545,500 |
| Married filing jointly | $98,900 | $613,700 | $613,700 |
| Married filing separately | $49,450 | $306,850 | $306,850 |
| Head of household | $66,200 | $579,600 | $579,600 |
Those are taxable income thresholds, not gain amounts. A married couple with $100,000 of other taxable income has already used up the 0% bracket before the gain starts, so in the $1M example none of the gain gets 0% — all $390,000 of the remaining gain is taxed at 15% and none of it reaches the 20% bracket.
The 25% rate on unrecaptured Section 1250 gain is a maximum, not a flat rate. Under the Schedule D worksheet, the recapture portion is taxed at ordinary rates up to the top of the 24% bracket ($403,550 married filing jointly, $201,775 single, for 2026) and at 25% only above that. In the $1M example the $150,000 of recapture cost $29,828 in federal tax — 19.9% effective, not 25% — because it was taxed at 12%, 22% and 24%. In the $2.5M example below, the full $400,000 of recapture does hit 25%, because the taxpayer’s income is already above the 24% bracket top. Calculators that multiply all depreciation by 25% overstate the tax for most sellers.
On top of the federal tax, the net investment income tax adds 3.8% on the smaller of your net investment income or the amount by which your modified adjusted gross income exceeds $200,000 (single or head of household), $250,000 (married filing jointly) or $125,000 (married filing separately). Those thresholds are not indexed for inflation. The calculator estimates your MAGI as your other taxable income plus the gain — the standard deduction does not reduce MAGI. In the $1M example the NIIT is $14,820.
Most states tax capital gains as ordinary income through graduated brackets. The calculator uses your state’s top marginal rate for 2026 as an estimate — California 13.3%, New York 10.9%, New Jersey 10.75%, Oregon 9.9%, Minnesota 9.85% — and nine states plus Washington have no personal income tax. Because a top rate applies only to the last dollars of income, this estimate usually runs high; change the rate field if you know your own effective rate. California’s 13.3% includes the 1% mental health services tax on income over $1 million. Washington has a separate 7% capital gains tax, but it exempts real estate, so Washington is 0% for a property sale.
Boot is anything you receive that is not like-kind property: cash left over plus debt relief. Recognized gain is the smaller of your boot and your total gain — you never pay tax on more than the gain itself. The calculator works it out from your cash flow: exchange funds are the sale price less selling costs less your old mortgage; the cash needed to close is the replacement price less the new mortgage. Cash left over is cash boot; debt relief net of any cash you add is mortgage boot. Cash you add to the deal reduces mortgage boot first, because it replaces debt you would otherwise have to take on.
To defer all of the gain you must trade up or equal on both tests: the replacement property must cost at least the amount realized, and the replacement debt plus any cash you add must at least equal the old mortgage. Fail either test and the shortfall is boot. In the $1M example the minimum replacement price is $940,000 and the minimum replacement debt is $500,000.
A delayed exchange runs on two clocks, and both start on the day your relinquished property closes — the day title transfers, not the day you sign the contract or open escrow. Both periods are counted in calendar days, and neither one moves for weekends or federal holidays. The only routine exceptions are IRS disaster relief for a federally declared disaster and combat-zone service.
| Deadline | What it is | When it ends |
|---|---|---|
| 45 days — identify | You must identify your replacement property (or properties) in a signed written notice delivered to your qualified intermediary or another party to the exchange. Sending it to your own attorney, CPA or agent does not count. | Midnight on the 45th day after closing. Treas. Reg. §1.1031(k)-1(b)(2)(i). |
| 180 days — close | You must receive (take title to) the replacement property. | The earlier of the 180th day after closing or the due date of your tax return for the year of the sale, including extensions. IRC §1031(a)(3). |
The two windows run at the same time, not back to back — the 45 days sit inside the 180. The return-due-date limit is the trap most sellers miss: sell in November without filing an extension and your April 15 return deadline cuts the exchange short by weeks. File Form 4868 and the due date moves to October 15, which restores the full 180 days.
You only need to satisfy one of the three IRS identification rules (Treas. Reg. §1.1031(k)-1(c)(4)):
Identify more than one property when you can — it is your fallback if your first choice falls through. Check your dates with the site’s exchange timeline calculator before your sale closes.
On the $1M California example the difference is stark. Sell outright and you pay $174,968 of tax from your $440,000 of sale cash, leaving $265,032 to reinvest. Exchange and the full $440,000 stays invested — $174,968 more working for you, compounding in the replacement property instead of going to the IRS and the Franchise Tax Board this year.
That is the whole case for the exchange in one line: it is not a tax cut, it is a bigger starting balance. The deferred gain carries into the replacement property’s basis, so a later sale without an exchange taxes the original gain plus any new appreciation. Hold until death and the basis steps up, which is why many investors exchange repeatedly and never pay the deferred tax in their lifetime. Use the site’s exchange vs sell-and-pay calculator to project the two paths over 10 or 20 years, and the capital gains deferral estimator for the federal-only view.
Every example below was computed with the same method the calculator uses — the Schedule D worksheet, 2026 brackets, 3.8% NIIT and the state top rate. Your numbers will differ.
Sale $1,000,000 · basis $400,000 · selling costs $60,000 · depreciation $150,000 · other taxable income $100,000 · California 13.3% · old mortgage $500,000 · replacement $1,000,000 with a $560,000 mortgage · no cash added · closes 15 January 2027.
The federal $88,328 breaks down as $58,500 at 15% (on the full $390,000 of remaining gain — none of it reaches the 20% bracket) plus $29,828 of recapture taxed at ordinary rates of 12%, 22% and 24% — not 25% — less the $7,640 of tax on your other $100,000 of income, which you pay whether or not you sell. The replacement mortgage is $560,000 rather than $500,000 because the $60,000 of selling costs comes out of the sale proceeds; the extra $60,000 of borrowing is the usual way a trade-up absorbs closing costs. Sell instead and only $265,032 of the $440,000 sale cash is left to reinvest.
Sale $650,000 · basis $300,000 · selling costs $40,000 · depreciation $80,000 · other taxable income $75,000 · Texas 0% · old mortgage $250,000 · replacement $650,000 with a $290,000 mortgage · closes 1 March 2027.
No state tax at all — but the tax bill is still nearly $60,000, which is why a Texas exchange is worth doing. The 180-day deadline falls on a Saturday: the deadline does not move to Monday, so plan to close the preceding Friday.
Sale $800,000 · basis $350,000 · selling costs $48,000 · depreciation $100,000 · other taxable income $120,000 · Florida 0% · old mortgage $300,000 · replacement $650,000 with a $200,000 mortgage · no cash added · closes 10 April 2027.
The replacement costs $102,000 less than the $752,000 amount realized, and that shortfall is exactly the boot: $2,000 of cash left over plus $100,000 of debt relief. Trading down is not free — it costs $21,000 of tax here — but it still defers $55,336. For the full boot calculation, use the site’s boot tax estimator.
Sale $2,500,000 · basis $600,000 · selling costs $150,000 · depreciation $400,000 · other taxable income $300,000 · New Jersey 10.75% · old mortgage $800,000 · replacement $2,500,000 with a $950,000 mortgage · closes 1 June 2027.
This is the case where recapture really is 25%: the full $400,000 costs $100,000, because the taxpayer’s income is already above the top of the 24% bracket. The 20% rate also bites here — $1,088,400 of the gain is taxed at 20% ($217,680). New Jersey’s 10.75% applies to income over $1 million, so it genuinely applies at this level.
Sale $400,000 · basis $320,000 · selling costs $24,000 · depreciation $20,000 · other taxable income $25,000 · Oregon 9.9% · old mortgage $150,000 · replacement $400,000 with a $174,000 mortgage · closes 15 February 2027.
Small numbers, but the mechanics show clearly: $20,550 of the gain falls in the 0% bracket and is taxed at nothing, the $20,000 of recapture is taxed at 10% and 12% (a $2,330 increment, not 25%), and there is no NIIT because MAGI of $81,000 is below the $200,000 threshold. Even so, Oregon’s 9.9% is more than half the total bill — state tax matters most on small gains.
Same sale as Example 3 — $800,000 sale, $350,000 basis, $48,000 costs, $100,000 depreciation, $120,000 other income, married filing jointly, Florida — but the replacement costs $800,000 with only a $200,000 mortgage, and the seller adds $148,000 of cash.
The replacement price passes the price test ($800,000 is above the $752,000 amount realized) and the $148,000 of cash added covers the $100,000 debt shortfall, so the minimum replacement debt drops to $152,000 and the $200,000 mortgage clears it. Adding cash is the standard fix when you want a smaller mortgage on the replacement property.
It defers the tax, it does not erase it. On the $1M California example on this page the exchange defers $174,968 — $88,328 federal, $14,820 net investment income tax and $71,820 California. What you save is the use of that money: $440,000 stays invested instead of $265,032 after tax. The deferred gain carries into the replacement property’s basis, so the tax comes due on a later sale without an exchange.
The exchange fails and the entire gain becomes taxable in the year of the sale. There is no extension for a slow lender, a failed inspection or a lost contract, and the deadline does not move for weekends or holidays. The only routine relief is an IRS disaster-relief notice for a federally declared disaster, or combat-zone service. Identify backup properties inside the 45 days so a failed first choice does not sink the exchange.
To defer all of the gain, yes on both tests: the replacement must cost at least the amount realized (sale price less selling costs) and the replacement debt plus any cash you add must at least equal the old mortgage. Buy for less and the shortfall is boot — Example 3 above trades down by $102,000 and pays $21,000 of tax on it. Adding cash fixes a debt shortfall, as Example 6 shows: $148,000 of cash added erased a $100,000 mortgage boot entirely.
25% is the maximum rate, not a flat rate. Under the Schedule D worksheet the recapture portion is taxed at ordinary rates up to the top of the 24% bracket ($403,550 married filing jointly, $201,775 single, for 2026) and at 25% only above that. In Example 1 the $150,000 of recapture cost $29,828 — 19.9% effective. In Example 4 the full $400,000 does hit 25% because the taxpayer’s income is already above the 24% bracket top. Calculators that multiply all depreciation by 25% overstate the tax for most sellers.
Yes to both. Federal deferral does not care which state the replacement property is in — a California seller can exchange into Texas property. Your state tax follows your state of residence, not the property’s state, so moving the property does not move the state tax. A Delaware Statutory Trust interest can be replacement property (Revenue Ruling 2004-86) and is a common choice for investors who want no landlord duties; see the site’s DST replacement guide. The exchange itself is reported on Form 8824 with your return.
This page is the flagship: the full tax-deferral calculation in one place. The tools below go deeper on one piece each.
Enter your sale above, check your minimum replacement price and debt, and confirm your 45-day and 180-day deadlines — then get your QI and CPA to confirm the exchange qualifies before the sale closes.
Back to the calculator