Deductions & credits

From pub 523: If you did not meet all the tests in Eligibility Step 1 through Eligibility Step 5,    earlier, your home is not eligible for the full maximum exclusion. However, you may still be eligible for partial exclusion if you can show the main reason you sold your home was because of a change in workplace location, for health reasons, or because of an unforeseeable event. See "Does Your Home Qualify—Details and Exceptions" [also in pub 523].