You may choose this status and use joint return tax rates if all five of the following apply:
Your spouse died within the two years prior to the current tax year and you did not remarry before the end of the current tax year,
You have a child or stepchild whom you claim as a dependent. This does not include a foster child.
This child lived in your home for all of the tax year you are completing. (Temporary absences by you or the child for a special circumstance, such as school, vacation, business, medical care, military service, or detention in a juvenile facility, count as time lived in the home.),
You paid over half the cost of keeping up your home,
You could have filed a joint return with your spouse the year he or she died, even if you did not actually do so.
If your spouse died during the year, you cannot file as qualifying widow(er) with dependent child. Instead, see the instructions for married filing joint on IRS Pub. 501.