Hello and thank you for your question. You are correct and selling a primary home may have potential tax consequences related to capital gains. I usually break down the calculations using the following formulas:
Basis Calculation: Capital Gains Calculation:
Original Purchase Proceeds
Improvements (Less selling expenses, i.e. commissions, closing costs, etc.)
(Less depreciation recapture, if any) (Less new basis)
New Basis Capital Gains
Please note that since this relates to a primary residence if you meet the qualifications the homeowner exclusion applies. I will also include a link from our support site that is helpful. Have a great day!
From TurboTax "Tax Aspects of Home Ownership: Selling a Home"