It is possible to have little or no equity and still owe tax.
Capital gain is arrived at by subtracting the adjusted basis from the adjusted sale price.
The adjusted sale price is the gross sale price minus standard transaction costs. There are a number of components used to arrive at the adjusted basis. Next, add to this figure all improvements made to the property which were not expensed. Then, subtract all depreciation taken over the period of ownership. To determine the estimated capital gain, subtract the adjusted basis from the sale price.