Opportunity Zone Calculator
Split a capital gain into the part a qualified opportunity fund investment can defer, the part taxed now, and any money invested beyond the gain.
Opportunity Zone Calculator
Background.
You have sold shares, a business interest or a building at a large profit, and someone has mentioned an opportunity fund. The idea is simple: reinvest the gain — not the whole sale price, only the gain — in a qualified opportunity fund within 180 days, elect deferral on your return, and the tax on that gain is postponed. Opportunity zones were created by the Tax Cuts and Jobs Act of 2017 and cover low-income census tracts in all 50 states, the District of Columbia and five US territories. You do not have to live or work in one to invest.
The first question is how much of the gain the investment actually covers. Deferral reaches only the amount of eligible gain you put into the fund, so a $250,000 gain with $200,000 reinvested leaves $50,000 taxable this year. Money you put in beyond the gain is not wasted, but it is a separate investment with none of the tax benefits. The calculator makes that three-way split.
The second question is when the deferred tax comes due, and the answer changed with the One Big Beautiful Bill Act of July 2025. For investments made on or before December 31, 2026, the original rule holds: the deferred gain is taxed in the year that includes the earlier of a sale or other inclusion event and December 31, 2026. Anyone holding one of those investments will report the remaining deferred gain on their 2026 return. For investments made on or after January 1, 2027, deferral runs for up to five years from the date of the investment, and new zones are designated for rolling ten-year periods, the first running from January 1, 2027 to December 31, 2036.
What is opportunity zone calculator?
Opportunity zone deferral is an election under section 1400Z-2 of the Internal Revenue Code to leave an eligible gain out of income for the year it is realized, to the extent that the same amount is invested in a qualified opportunity fund within 180 days. Eligible gains are capital gains and qualified section 1231 gains, the gains on business property held for more than a year. A qualified opportunity fund is a corporation or partnership organized to invest in zone property, which certifies itself to the IRS each year on Form 8996. The investor's starting basis in the fund is zero, which is how the deferred gain is preserved for later taxation.
How to use this calculator.
- Enter the eligible gain: the capital gain or section 1231 gain from the sale, as it would appear on Form 8949 or Form 4797 — the gain, not the proceeds. If the gain came to you through a partnership or S corporation K-1, use the figure reported to you.
- Enter the amount you invested, or plan to invest, in the qualified opportunity fund within the 180 days. The window generally starts on the day the gain would be recognized; for gain passed through a partnership you can instead start it on the last day of the partnership's tax year or on the partnership return's unextended due date.
- Read the three results. The deferred figure is what your election can cover, the amount not covered is taxable in the year of the sale, and any surplus investment is outside the program.
- Check the investment date against December 31, 2026, because it decides how long the deferral lasts, and confirm with the fund that it is certified on Form 8996. You make the deferral election on Form 8949 and report the holding each year on Form 8997.
The formula.
The calculation is three comparisons. Deferred gain = min(G, I), where G is the eligible gain and I is the amount invested in the fund. Gain recognized now = max(G − I, 0): the part of the gain your investment did not cover, taxed in the ordinary way in the year of the sale. Investment above the gain = max(I − G, 0): money that the law treats as a separate, non-qualifying interest in the fund, with no deferral, no basis increase and no ten-year exclusion. The arithmetic stops there on purpose. It does not test whether the 180-day deadline was met, whether the fund qualifies, or how long you will hold, and it does not compute the tax on any figure. When the deferred gain is eventually included, the amount taxed is the deferred gain or, if the fund interest is worth less by then, its fair market value, reduced by any basis increase you have earned — so the deferred figure is the most that can be taxed later, not a prediction.
A worked example.
An investor sells a block of shares and realizes a $250,000 long-term capital gain. Within 180 days they put $200,000 into a qualified opportunity fund and elect deferral. The deferred gain is the smaller of the gain and the investment: min($250,000, $200,000) = $200,000. The uncovered gain is $250,000 − $200,000 = $50,000, which is reported and taxed for the year of the sale. Because the investment did not exceed the gain, nothing falls outside the program: max($200,000 − $250,000, 0) = $0. What happens to the $200,000 depends on the date of the investment. Made in 2026, it is taxed on the 2026 return. Made on or after January 1, 2027 and held five years, it is taxed in the fifth year, but the investor's basis rises by 10% of the deferred gain, so $20,000 is never taxed and $180,000 is included — assuming the fund interest is still worth at least $200,000. In a qualified rural opportunity fund the increase is 30%, leaving $140,000 to include.
Frequently asked questions.
Do I have to reinvest the whole sale price, or just the gain?
I sold an asset in the second half of 2026. Should I invest before or after January 1, 2027?
What happens to my existing opportunity fund investment at the end of 2026?
What is the ten-year benefit, and does it still exist after the 2025 law?
What if I invest more than my gain?
Which forms do I file?
References& sources.
- [1]IRS Opportunity Zones; eligible gain, qualifying investment and deferral rules. Retrieved 2026-08-07.
- [2]U.S. Internal Revenue Service. About Form 8996, Qualified Opportunity Fund. Retrieved 2026-08-07.
- [3]U.S. Internal Revenue Service. Publication 544, Sales and Other Dispositions of Assets. Retrieved 2026-08-07.
How this page was produced
- Published by
- Quanta Calculator
- Overseen by
- Daniel, Quanta Calculator Researcher
- Primary sources
- 3 cited below
- Method
- simplified gain deferral = min(eligible gain, amount timely invested in a qualified opportunity fund); eligibility and recognition dates are outside scope
- Published
- Last verified
Built with AI assistance and verified by automated tests against the cited sources — every worked example on this page is computed by the same code that runs the calculator. How we build and check calculators.
In this category
Embed
Quanta Pro
Paid features are coming later.
- All 1560 calculators remain free
- No billing is enabled