Hello and thank you for using Just Answer
If you are a U.S. citizen or resident alien, the rules for filing income, estate, and gift tax returns and paying estimated tax are generally the same whether you are in the United States or abroad. Your worldwide income is subject to U.S. income tax, regardless of where you reside. However, you may qualify to exclude from income up to an amount of your foreign earnings that is now adjusted for inflation ($91,400 for 2009, $91,500 for 2010, $92,900 for 2011). In addition, you can exclude or deduct certain foreign housing amounts.
You must be one of the following to take advantage of the exclusion:
You were not required to "declare" residency in the US to be required to file your US return. As a citizen you are required to declare all income and report but as I advised previously, there are beneficial treatments to taxation for you, provided you meet the requirements. Do your return for Spain to see if you will be given a refund of the withholding then you will know if you can use the Foreign Tax Credit to assist you with the US return.
Thank you for your quick response. So just to be clear, I need to file a tax return in Spain
Sorry about that, didn't mean to send
So I need to file a tax return in both the United States and Spain? My taxes were already taken out of my paychecks while I was there. I have a document from my work's accountant that declares my earnings and deductions. It's rough translation is certificate of tax retention for non residents.