What are my tax consequences

I am looking at selling a portfolio of rental properties for $5.3M. The buyer is able to obtain a loan for $3.44M and I will take back a second mortgage of the balance of $1.85M. My question is this. Do I have to pay capital gains on the entire amount of the sale right away, or do I pay taxes on the amount of the second mortgage after I have collected it?

What are my tax consequences

As a general rule, for an installment sale, you pay the tax on all of the unrecaptured depreciation in the year of the sale – one lump sum, no installments. On the capital gain due to appreciation, you pay tax on the profit in the year it is received. Interest on the note you are carrying back is taxable when it is received.