The Treasury Department announced Thursday that it will treat legally married same-sex couples as married for federal tax purposes, regardless of whether the state the couple lives in recognizes gay marriage.

In a press release, Treasury Secretary Jacob Lew said that “today’s ruling provides certainty and clear, coherent tax filing guidance for all legally married same-sex couples nationwide.”

The ruling will mean that the federal government treats legally married same-sex couples as married wherever marriage interacts with federal tax law, not just for income tax purposes. The ruling is relevant for tax filing status, IRA contributions and tax credits like the earned income tax credit and the child tax credit, according to the Treasury.

Anyone in a legally recognized same-sex marriage must file as “married filing jointly” or “married filing separately” for 2013. Individuals who would have been eligible to file as married under the provision can submit an amended tax return for the years 2010, 2011, and 2012 to get a refund that would have been owed.

Treasury’s announcement follows the Supreme Court’s June decision striking down part of the Defense of Marriage Act and ruling that same-sex couples who are legally married are entitled to all the rights afforded married couples under federal law.