I'm sorry to hear about your troubles. The IRS law on point would say that the first to file gets the tax benefits. The benefits should only go to the parent who had the child for the most overnights throughout the year. You could fight this with the IRS, and report his improper claim, or you could investigate filing against him in state court, though he is out of state, and there may be jurisdictional issues. Every tax situation is unique and I would recommend having an assessment with an experienced advocate that can assist you with this.