When you sell equipment, a building or other property used in your business, Form 4797 decides how much of the gain is taxed as ordinary income and how much gets capital gain treatment.
This guide explains the three parts of the form, how depreciation recapture works with a worked example, the five-year rule for section 1231 losses and how installment sales and exchanges fit in, using the 2025 Form 4797 and its instructions.
The IRS says Form 4797 reports the sale or exchange of real property used in your trade or business, depreciable and amortizable tangible property used in your trade or business, and certain mineral and cost-sharing payment property, plus involuntary conversions (other than casualty or theft) of business property. Sales of capital assets generally go on Form 8949 and Schedule D instead; see our Form 8949 guide and Schedule D guide. Gain from depreciable property held for investment rather than business is generally capital gain, though part may be ordinary. If you sold a home you also used for business, you may need Form 4797 for the business part.
| Part | What goes there | IRS rule |
|---|---|---|
| Part I | Section 1231 transactions not required in Part III: business real and depreciable property held more than 1 year, involuntary conversions and certain livestock | Net gain is generally a long-term capital gain on Schedule D unless you have nonrecaptured section 1231 losses |
| Part II | Ordinary gains and losses, including property held 1 year or less and transactions not reportable in Part I or III | Ordinary income or loss |
| Part III | Gain on property subject to depreciation recapture under sections 1245, 1250, 1252, 1254 and 1255 | Recapture reported as ordinary income on line 13 via line 31 |
For property held 1 year or less the IRS says generally do not complete Part III; use Part II. The holding period starts the day after you received the property and includes the day you disposed of it.
Section 1245 property is depreciable property such as personal property and certain other items; section 1250 property is depreciable real property other than section 1245 property. On Part III you enter gross sales price (line 20), cost or other basis (line 21) and depreciation allowed or allowable (line 22); adjusted basis (line 23) is line 21 minus line 22, and total gain (line 24) is line 20 minus line 23. For section 1245 property the ordinary amount (line 25b) is the smaller of the gain or the depreciation allowed. Line 31 carries recapture to line 13, and line 32 (total gain minus recapture) goes to Part I, line 6 when it is not from casualty or theft.
| Example (our illustration) | Sold for $35,000 | Sold for $60,000 |
|---|---|---|
| Cost $50,000, depreciation $30,000, adjusted basis | $20,000 | $20,000 |
| Total gain (line 24) | $15,000 | $40,000 |
| Ordinary recapture (smaller of gain or $30,000, line 25b) | $15,000 | $30,000 |
| Section 1231 gain left for Part I (line 32) | $0 | $10,000 |
This assumes section 1245 property sold at a gain after being held more than 1 year. For section 1250 property (depreciable real property) the form says to enter -0- on the recapture line if straight-line depreciation was used (except for a corporation subject to section 291), so the same sale of a building would usually produce little or no ordinary recapture on Form 4797.
Your nonrecaptured section 1231 losses are your net section 1231 losses deducted during the 5 preceding tax years that have not yet been applied against net section 1231 gain. Net section 1231 gain is treated as ordinary income to that extent. The IRS example: net section 1231 losses of $4,000 in 2020 and $6,000 in 2021, then net gains of $3,000 in 2024 and $2,000 in 2025. The $2,000 gain for 2025 goes on line 7, the nonrecaptured losses of $7,000 ($10,000 of net losses minus the $3,000 the IRS shows as already applied against net gain) go on line 8, and the entire $2,000 is ordinary income on line 12. If you have no nonrecaptured losses, the gain is a long-term capital gain on Schedule D.
If you sold property at a gain and will be paid in a later year, you generally must use the installment method unless you elect not to, reporting on Form 6252; section 1231 gain from an installment sale goes on line 4. Exchanges of qualifying business or investment real property for like-kind property are reported on Form 8824, with section 1231 gain or loss on line 5 and ordinary gain on line 16. If you disposed of both depreciable property and other property (for example a building and land) in one transaction at a gain, you must allocate the amount realized between them by fair market value. Business owners also see Schedule C, Schedule E and Schedule 1 (line 4 reports other gains).
IRS: Instructions for Form 4797, Sales of Business Property, IRS: Form 4797, Sales of Business Property.
Next-year note: the IRS has posted an early-release 2026 draft of Form 4797 (marked not for filing). It renumbers lines; for example the section 1245 recapture line 25b becomes 27b and the Part III recapture total moves from line 31 (carried to line 13) to line 33 (carried to line 14). This guide follows the final 2025 form and instructions used to file in 2026; check the line numbers against the form you file.