Hal_Al
Level 15

Deductions & credits

Normally the IRS does not allow you to conduct a 1031 exchange with your primary residence. But, in you circumstances, it can possibly be done. See https://learn.roofstock.com/blog/1031-exchange-primary-residence

 

As to home sale exclusion; it depends on more details.  When do your move out (exact date)? When you moved to NJ was it for a new job (or did you start a new job after moving. There is a partial exception to the two year rule (but not the five year rule) for a job change or other "unforeseen circumstances".