Skip to main content

Form 4797 Demystified: How Depreciation Recapture and Section 1231 Decide Whether Your Business Sale Is Ordinary or Capital

· 13 min read
Mike Thrift
Mike Thrift
Marketing Manager

You sold a $200,000 piece of equipment, expected a clean long-term capital gain, and your CPA hands you a tax bill that looks like ordinary income. What happened? Welcome to Form 4797 — the form where the IRS quietly claws back every depreciation deduction you've ever taken before letting any of your gain enjoy the friendly capital gains rate.

Form 4797 is one of the most misunderstood forms in the tax code. It governs every sale of a business asset that isn't reported on Schedule D, and the dollar swings between getting it right and getting it wrong can be enormous. A property classified incorrectly can shift income between a 37% ordinary rate and a 20% capital rate. A forgotten lookback rule can turn a year of capital gains into a year of ordinary income with no warning. The form rewards careful reporting and punishes guesswork.

2026-05-07-form-4797-sale-of-business-property-depreciation-recapture-section-1231-gains-ordinary-capital-treatment-guide

This guide walks through what Form 4797 actually does, how Section 1245 and Section 1250 recapture work in practice, why Section 1231 is the most generous "have-your-cake-and-eat-it" provision in the tax code, and how to avoid the mistakes that trigger CP2000 notices and amended returns.

What Form 4797 Actually Reports

Form 4797 — Sales of Business Property — is the IRS's catchall for dispositions of property used in a trade or business. It covers assets a typical Schedule D filer never sees: depreciable equipment, rental real estate, intangible business assets, livestock used for breeding, and even self-created intellectual property used in business.

The form reports gains and losses from:

  • Sales and exchanges of business property held more than one year
  • Sales of business property held one year or less
  • Involuntary conversions (theft, casualty, condemnation) of business property
  • Recapture of depreciation under Sections 1245 and 1250
  • Recapture of Section 179 expensing and Section 280F bonus depreciation when business use drops below 50%
  • Mark-to-market gains and losses for traders who elected Section 475(f)
  • Disposition of Section 197 intangibles like goodwill, going concern value, customer lists, and franchise rights

The most important thing to understand about Form 4797 is that it doesn't just compute gain — it determines the character of that gain. Ordinary or capital. Long-term or short-term. Recapture or non-recapture. The same dollar of profit can be taxed at wildly different rates depending on which line of which part it lands on.

The Four Parts of Form 4797 and the Order to Complete Them

Form 4797 has four parts, and counterintuitively, you do not fill them out in numerical order. The proper sequence is Part III, then Part I, then Part II, then Part IV. Here's what each part does and why the order matters.

Part III: Recapture First

Part III calculates depreciation recapture for property held more than one year. You start here because Part III determines how much of your total gain is recharacterized as ordinary income before any Section 1231 treatment. Whatever recapture amount Part III spits out flows up to your ordinary income line. The remaining gain — what's left after recapture — is what gets sent down to Part I for Section 1231 netting.

Part III handles three categories of property:

  • Section 1245 property — depreciable personal property like machinery, vehicles, equipment, furniture, and most intangibles. Recapture is the lesser of total depreciation taken or total gain.
  • Section 1250 property — depreciable real property like buildings and structural components. Recapture is limited to "additional depreciation" beyond straight-line, which for property placed in service after 1986 is essentially zero (because the code mandates straight-line). What survives is the unrecaptured Section 1250 gain — taxed at a special 25% maximum rate.
  • Section 1252, 1254, and 1255 property — farmland soil expenditures, oil and gas properties, and cost-sharing payment property. Each has its own narrow recapture rule.

Part I: Section 1231 Property Held More Than One Year

Part I is where Section 1231 transactions go after Part III has skimmed off any recapture. Part I also captures property that has no recapture to compute — most commonly land (which isn't depreciable) and depreciable Section 1231 property sold at a loss (recapture only applies to gains).

The magic happens in the Part I netting. If your total Section 1231 gains exceed your total Section 1231 losses, the net gain is treated as long-term capital gain. If your losses exceed your gains, the net loss is treated as ordinary loss. This is the famous Section 1231 "best of both worlds" treatment — you get capital gain rates on the upside and full ordinary loss deductibility on the downside.

Part II: Ordinary Gains and Losses

Part II reports business property dispositions that are explicitly ordinary income or ordinary loss:

  • Property held one year or less (no long-term capital gain treatment available)
  • Inventory and accounts receivable (never capital assets)
  • Section 179 recapture when business use drops
  • Ordinary income from Part III recapture flows here

If you sold equipment after only seven months, you skip Part I and Part III entirely and go directly to Part II.

Part IV: Section 179 and Listed Property Recapture

Part IV is the trap that catches taxpayers who claimed accelerated deductions and then changed their use pattern. If you Section 179'd a $40,000 truck assuming 100% business use, and three years later your business use drops to 40%, Part IV recaptures the excess deduction. Same logic applies to Section 280F bonus depreciation on luxury autos and listed property — drop below 50% business use and a chunk of your prior deductions reappears as ordinary income.

How Section 1245 Recapture Actually Works

Imagine you bought a CNC machine for $100,000 in 2021. By 2026 you've claimed $80,000 in depreciation, leaving an adjusted basis of $20,000. You sell the machine for $90,000.

Your total gain is $90,000 minus $20,000, or $70,000.

Section 1245 says: every dollar of that gain, up to the $80,000 of depreciation you claimed, is ordinary income. Since your gain ($70,000) is less than your prior depreciation ($80,000), the entire $70,000 is recaptured as ordinary income. None of it gets capital gain treatment.

Now flip the example. You sell the same machine for $130,000. Total gain is $110,000. The first $80,000 (the depreciation amount) is ordinary income recapture. The remaining $30,000 — the gain that exceeds your original cost — is treated as Section 1231 gain and flows to Part I, where it could qualify for long-term capital gain rates after netting.

This is the "allowed or allowable" rule that quietly bites careless taxpayers: even if you forgot to claim depreciation, the IRS reduces your basis as if you had, and the recapture still applies. You don't get to skip recapture by skipping deductions.

Why Section 1250 Recapture Looks Generous (Until It Isn't)

Section 1250 governs depreciable real estate — commercial buildings, rental properties, warehouses. On paper it sounds like a relief: only "additional depreciation" beyond straight-line gets recaptured as ordinary income. And since real property placed in service after 1986 must use straight-line depreciation, there's nothing to recapture under Section 1250 itself.

So real estate is taxed at capital gain rates? Not quite.

Enter the unrecaptured Section 1250 gain — the most overlooked tax provision in real estate. The portion of your gain attributable to depreciation taken on Section 1250 property is taxed at a maximum federal rate of 25%, not the 15% or 20% long-term capital gain rate. The rest of the gain — appreciation above original cost — gets ordinary long-term capital gain rates.

Example: You bought a rental property for $400,000 in 2014. By 2026 you've claimed $145,000 in straight-line depreciation, putting your adjusted basis at $255,000. You sell for $600,000.

  • Total gain: $345,000
  • Unrecaptured Section 1250 gain (lesser of depreciation or gain): $145,000 — taxed at up to 25%
  • Remaining long-term capital gain: $200,000 — taxed at 15% or 20%

If you assumed the entire $345,000 would hit at 20%, you're underwithholding by roughly $7,000 in federal tax alone, before considering net investment income tax (3.8%) and state taxes.

The Section 1231 Netting and Lookback Rule

Section 1231 is famous for its "heads I win, tails you lose" treatment: net gains become long-term capital gain, net losses become ordinary loss. But Congress added a guard against gaming the system — the five-year lookback rule.

Here's the rule in plain English: if you've taken any net Section 1231 losses (deducted as ordinary) in any of the prior five tax years, your current-year net Section 1231 gains are recharacterized as ordinary income up to the amount of those unrecaptured prior losses. Only after you've "paid back" the prior ordinary loss benefits does the remaining gain qualify for capital gain treatment.

Example: In 2024 you had a $50,000 net Section 1231 loss and deducted it against ordinary income. In 2026 you have a $80,000 net Section 1231 gain. The first $50,000 of your 2026 gain is taxed as ordinary income (recharacterizing the prior benefit). Only the remaining $30,000 gets long-term capital gain treatment.

The lookback rule is a five-year sliding window. Tracking your "nonrecaptured net Section 1231 losses" across multiple years requires meticulous records — and this is where many taxpayers get blindsided when their CPA pulls up prior returns and finds an old loss they forgot about.

Common Form 4797 Mistakes That Cost Real Money

After years of CPA war stories and IRS notices, the same errors keep appearing:

1. Filing personal-use property on Form 4797. The form is for property used in a trade, business, or for the production of income. Your personal car, vacation home, or hobby equipment goes on Schedule D (or isn't deductible at all). Mixing personal items into Form 4797 invites scrutiny.

2. Forgetting to reduce basis for "allowed or allowable" depreciation. If you should have claimed depreciation but didn't, the IRS still reduces your basis. The fix is to file Form 3115 to claim missed depreciation as a Section 481(a) adjustment — but only before you sell.

3. Misreporting like-kind exchanges. A 1031 exchange goes on Form 8824 first; the resulting gain or loss recognized (if any) flows to Form 4797. Skipping Form 8824 and putting everything on Form 4797 directly typically triggers IRS computer matching and a notice.

4. Using the installment method incorrectly. When you sell business property on installment, depreciation recapture must be fully recognized in the year of sale even if you receive only one payment that year. Only the non-recapture portion of the gain spreads over the installment period via Form 6252. This mismatch trips up taxpayers who expect all the income to defer.

5. Misclassifying property between Section 1245 and Section 1250. Equipment permanently affixed to a building can blur the line. The IRS scrutinizes property classifications because the difference between full ordinary recapture (1245) and limited recapture (1250) can be enormous. Cost segregation studies frequently get challenged here.

6. Ignoring the Section 1231 lookback. If you took a Section 1231 loss in any of the last five years, build a tracking schedule. Don't rely on memory.

7. Forgetting Section 179 and bonus depreciation recapture when business use drops. Sole proprietors and small business owners who use a vehicle 80% for business one year and 30% the next often don't realize they owe recapture under Section 280F. The reduction in business use itself triggers tax — no sale required.

The Bookkeeping Behind Every Form 4797 Calculation

Every line on Form 4797 ultimately depends on three numbers per asset: original cost, accumulated depreciation, and sale proceeds. Get any one of those wrong and the entire computation cascades into error.

This is where disciplined bookkeeping pays off years before you ever sell. The asset register should track, per asset: acquisition date, original cost (including capitalized improvements), accumulated depreciation by year, current adjusted basis, and the depreciation method used. When you sell, you should be able to pull the entire history in seconds — not reconstruct it from receipts and bank statements.

Plain-text accounting is particularly well-suited to this because every transaction, including depreciation entries and basis adjustments, lives in a version-controlled, human-readable ledger. You can grep for an asset by name, see its full history, and verify your basis the same way you'd verify any other line in your books.

Tax Planning Around Form 4797

Smart sellers think about Form 4797 long before they sign a sales contract. A few moves that can shift outcomes meaningfully:

Time the sale to manage the lookback window. If you're approaching the end of the five-year window after a Section 1231 loss, waiting a few months can mean the difference between ordinary and capital treatment.

Consider an installment sale to spread non-recapture gain. Even though recapture must be recognized immediately, deferring the residual capital gain over multiple years can keep you out of higher brackets.

Use 1031 exchanges for real estate. A properly structured like-kind exchange defers both the unrecaptured Section 1250 gain and the long-term capital gain — though only for real property held for productive use in a trade, business, or investment.

Watch your QBI implications. Gains on Section 1231 property treated as long-term capital gain are excluded from qualified business income. Recharacterized gains under the lookback rule, however, may count as ordinary income for QBI — which can interact with the 20% deduction in surprising ways.

Document basis and improvements during ownership. A capitalized roof replacement on a rental property increases basis and reduces gain on sale. Treating it as a deductible repair increases current-year deductions but inflates eventual gain. Get this categorization right at the time of expense, not at the time of sale.

Keep Your Asset Records Audit-Ready From Day One

Form 4797 mistakes almost always trace back to incomplete records — depreciation schedules that don't match returns, missing basis adjustments, untracked improvements, forgotten Section 1231 losses. By the time you're filling out the form, the data either exists cleanly or it doesn't. Beancount.io provides plain-text accounting that gives you complete transparency and version history over every transaction, asset, and depreciation entry — no black boxes, no vendor lock-in, and no rebuilding your basis from a shoebox of receipts. Get started for free and turn your asset records into something you can actually trust when it's time to sell.