# US tax resident to non-resident. When does it happen, capital gains and does the US-Germany tax treaty impact it?



## lzr (Dec 22, 2020)

If you are a tax advisor well versed with non-resident questions or know one, feel free to shamelessly advertise via direct message.

I am considering moving from the US to Germany. I am a German citizen, currently in the US on a *non-immigrant work visa*. I am wondering exactly when my US tax status would change back to non-resident if I were to move back to Germany and what would happen if I realized capital gains during some periods of ambiguity 

For simplicity, let's assume I would move either in December 2022 or January 2023. I spent 183 days or more in the US during 2022, and since I was here on January 1, I would be a tax resident from the beginning of the year.

My general understanding, before any tax treaties, is that there are three cases:

If I were to leave before the end of 2022, I would be a tax resident at least until my day of departure. When filing my 2022 tax return, I could choose to *(a)* declare my departure to become a non-resident for the remainder of the year. But I could also choose to *(b)* not declare my departure and remain a tax-resident throughout the year. Declaring my departure does not seem desirable. It would turn me into a dual-status resident, meaning I would have to paper file the tax return and would not get the standard deduction.
I leave on December 31. That leaves no ambiguity. Resident for all of 2022, non-resident starting for all of 2023.
I leave in January 2023, no later than January 30. That means I fail the 31 days of presence part of the substantial presence test and would only be a non-resident for the entirety of 2023. That means FATCA and FBAR would also not apply for 2023.
So far, so good. Now I am wondering, does the tax treaty between the US and Germany modify any of this? 

Does it force me to switch to non-resident status after my departure from the US, or upon my arrival in Germany? I.e., force me into dual status in *case 1* or *case 3*.
What if I depart the US, but travel to a third country for a few days for leisure? When would my status change then?

Now, regarding the taxation of capital gains from selling stocks. This is governed by Article 13.5 of the tax treaty, which says these gains may only be taxed in the country of residence at the time of sale. 

Case *1 (a)* seems straightforward, since max tax status would change as I moved.
What would happen in case *1 (b)*, where I would still be a US tax resident, but at the same time have my actual residence in Germany already? I assume gains during this time would be taxable in the US, due to both the saving clause and me legally being still a resident. And Germany may or may not decide to tax me, since I am already getting taxed in the US. I assume this could be avoided by staying in a third country for the remainder of the year, which would take Germany out of the question.
*Case 3*, I would be physically present in the US and realize gains, but also a non-resident. Would I pay the 30% non-resident tax on these gains?


----------



## Moulard (Feb 3, 2017)

lzr said:


> So far, so good. Now I am wondering, does the tax treaty between the US and Germany modify any of this?
> 
> Does it force me to switch to non-resident status after my departure from the US, or upon my arrival in Germany? I.e., force me into dual status in *case 1* or *case 3*.
> What if I depart the US, but travel to a third country for a few days for leisure? When would my status change then?


You will always have a tax residency. With the exception of US citizens you only ever have have one tax residence at a time
By international norms you would remain a US tax resident until such time as you met the German definition of a tax resident. 
Where both the US and Germany could claim you as a tax resident, the tax treaty tie breaker rules come into play - which would almost certainly come out as German Tax Residence.





lzr said:


> Now, regarding the taxation of capital gains from selling stocks. This is governed by Article 13.5 of the tax treaty, which says these gains may only be taxed in the country of residence at the time of sale.


Unless I am mistaken, shares fall under 13(2)(b) and the gains will be considered sourced on the tax residency of the company. If they are shares in a US company, then the income will be considered US sourced and the US will have the primary right to tax that income.

Which basically changes the equation to...

Sell the shares while a US tax resident, report on a 1040 as part of your global income (and be taxed at the resident rate)
Sell the shares after no longer a tax resident report on a 1040NR as US sourced income (and be taxed at the non-resident rate)


----------



## lzr (Dec 22, 2020)

Moulard said:


> By international norms you would remain a US tax resident until such time as you met the German definition of a tax resident.
> Where both the US and Germany could claim you as a tax resident, the tax treaty tie breaker rules come into play - which would almost certainly come out as German Tax Residence.


So do I see it correctly then: If I leave the US in December, travel around third countries for the remainder of the year, without any intent to establish residency in a third country, and only return to Germany the following year, would that avoid a dual status year and be as clean as moving on Dec 31? 

The US would see me as tax resident through the year, unless I voluntarily establish that I left before the end of the year. Germany should not claim me as tax resident until I actually establish residency there, which would be in the following year. There would be no overlap between the US and Germany and nothing for me to worry about. Other than losing my baggage.


----------



## Moulard (Feb 3, 2017)

Pretty much how I would approach it.

File a normal 1040 for the 2022 tax year and then a 1040-NR for the 2023 tax year if you had any US Sourced income.

If you have been in the US for an extended period, you might contemplate filing a 1040-NR in 2023 even if you had no US sourced income as it creates a clean break from a tax records respective...

Beyond that you would only have to file a 1040NR if you ever had US sourced income in the future.

You just have to decide whether you wish to sell the shares before or after you leave the US to control how the gain is taxed.


----------



## lzr (Dec 22, 2020)

By "how I would approach it," do you mean being a tourist in a third country until the end of the year?

I do expect US-sourced income for the following year, so 1040-NR is expected.

Regarding capital gains, most likely I will just avoid any taxable transactions during times of ambiguity.


----------

