The home sale exclusion lets you omit from gross income up to $250,000 of gain ($500,000 on a joint return), but only if you meet certain conditions:
A fixed deduction allowed to every taxpayer, except those who may be claimed as a dependent by another person. Extra exemption deductions are allowed for a spouse on a joint return and for each qualifying dependent. A deduction of $3,400 is allowed for each exemption claimed on 2007 returns, but the deduction is phased out for certain high income individuals.