You are a U.S. resident for tax purposes if you meet either the green card test or the substantial presence test for the calendar year, or if you make a valid first-year election under the residency rules. That is the direct answer, but the word "resident" here means something narrower than it does in everyday speech. It has nothing to do with where you vote, where your family lives, or what you call home. It is a technical immigration-and-calendar test defined in the Internal Revenue Code, and a person can be a tax resident without ever holding a green card, just as a green card holder can be a tax resident while living abroad.
Many people searching for this question are actually wondering whether they are a "resident alien" for U.S. income tax purposes, usually because they are a foreign national studying or working in the United States, or because they moved to the U.S. partway through the year. This article answers that question: who counts as a U.S. resident for tax purposes, how the two main tests work, which exceptions apply, and how the answer changes your filing obligations.
Resident Alien vs. Nonresident Alien
U.S. tax law divides foreign nationals into two categories: resident aliens and nonresident aliens. A U.S. citizen is always taxed on worldwide income; a resident alien is treated largely the same way. A nonresident alien is taxed only on U.S.-source income and is subject to different withholding, reporting, and treaty rules.
The label "resident alien" is a tax status, not an immigration status. You can hold a nonimmigrant visa and still be a resident alien for tax purposes. Conversely, a lawful permanent resident who has lived outside the U.S. for years can remain a tax resident because of the green card test.
The two tests that determine this status are the green card test and the substantial presence test, and you need to meet only one of them.
The Green Card Test
You are a U.S. resident for tax purposes if you were a lawful permanent resident of the United States at any time during the calendar year. In practice, that means you held an alien registration card, commonly called a green card, at some point during the year.
The key point is that this test does not depend on how many days you spend in the country. A green card holder who spends most of the year abroad is still a tax resident unless the card has been revoked or abandoned through formal administrative or judicial action. Simply moving away, letting the card sit unused, or intending to give it up does not end resident status for tax purposes. That is a common and costly misunderstanding: people assume that living overseas makes them nonresidents, but the tax law looks at the card, not the address.
The Substantial Presence Test
If you do not hold a green card, the substantial presence test decides your status based on days present in the United States. You are a resident alien if you were physically present in the U.S. for at least 31 days during the current year and at least 183 days during the three-year period that includes the current year and the two years immediately before it, counting days with a weighted formula.
The formula works like this:
| Year | Days present | Weight applied | Counted days |
|---|---|---|---|
| Current year | Every day | 1 | Full count |
| First preceding year | Every day | 1/3 | One-third |
| Second preceding year | Every day | 1/6 | One-sixth |
Add the counted days from all three years, and the total is your "substantial presence" number. If it reaches 183 and you were present at least 31 days in the current year, you meet the test.
Here is an illustration. Suppose you were in the U.S. 120 days this year, 120 days last year, and 120 days two years ago. The calculation is 120 + (120 ÷ 3 = 40) + (120 ÷ 6 = 20) = 180. That is below 183, so you would not meet the substantial presence test on those numbers alone. Change the current-year figure to 130 days and the total becomes 190, which does meet the test.
Two definitions matter for the day count. A day of presence generally means any day you were physically in the U.S. at any time, including partial days, with limited exceptions for days spent in transit between two foreign points. And days spent in the U.S. as a commuter from Canada or Mexico are generally not counted when you regularly commute to work in the U.S. and return home.
The Exempt-Individual Exception
Some days do not count toward substantial presence at all, even though you were physically in the country. These belong to the "exempt individual" rules, and they are the reason many students and teachers are surprised to learn they are nonresidents even after years in the U.S.
Under these rules, you do not count days of presence if, during the year, you were:
A foreign-government-related individual temporarily present under an A or G visa (with narrow exceptions for certain permanent-resident-type situations)
A teacher or trainee temporarily present under a J or Q visa who substantially complies with the visa requirements A student temporarily present under an F, J, M, or Q visa who substantially complies with the visa requirements A professional athlete temporarily present to compete in a charitable sports event
These exemptions are time-limited. Students on F, J, M, or Q visas generally exclude days for up to five calendar years, and teachers and trainees on J or Q visas for up to two calendar years, after which the days start counting. The exact counting rules have nuances, especially around when the clock begins and how prior years interact, so anyone relying on this exception should consult the relevant IRS guidance or a tax professional rather than assume a simple five-year window.
The Closer Connection Exception
There is a limited escape hatch from the substantial presence test. Even if you meet the day-count math, you can be treated as a nonresident if you satisfy all of the following: you were present in the U.S. fewer than 183 days in the current year, you have a tax home in a foreign country during the year, and you have a closer connection to that foreign country than to the United States. You must also file the appropriate statement with your return.
This exception is narrow. It cannot help someone who was physically present 183 days or more in the current year, and it is unavailable to green card holders. It exists mainly for people whose travel pattern pushes them over the three-year weighted threshold without any single year reaching 183 days.
First-Year and Residency-Starting Elections
The calendar-year rules can create awkward results for people who move to the U.S. midyear. Two elections exist to smooth this out.
The first-year election lets someone who becomes a resident under the substantial presence test in the current year, but was not a resident in the prior year, elect to be treated as a resident for the entire year, provided they meet the day-count and other requirements. This can allow a joint return with a spouse and access to resident deductions and credits.
A separate residency-starting-date election allows a person who becomes a resident during the year to be treated as a resident from the first day of physical presence, which can be useful for treaty and filing purposes. Both elections have technical requirements, including timely filing, and choosing them changes which income is taxed and which forms you file.
What Changes If You Are a Resident
Resident status changes the scope of what you report. As a resident alien, you generally report your worldwide income on Form 1040, the same form citizens use, and you may claim the standard deduction, certain credits, and deductions that nonresident aliens cannot. You may be able to file jointly with a spouse and claim dependents.
Nonresident aliens generally file Form 1040-NR, report only U.S.-source income (plus certain foreign-source income connected to a U.S. business), and face different withholding rules. They may also use tax treaties to reduce U.S. tax on certain income, and treaties can override the statutory residency rules in specific cases, sometimes allowing a person who would otherwise be a resident to be treated as a nonresident, or vice versa.
This is why the question "am I a U.S. resident for tax purposes" matters so much: the answer determines the form you file, the income you must report, the credits and deductions available, and the penalties that may apply for getting it wrong.
Circumstances That Commonly Change the Answer
Several situations trip people up.
Moving to or from the U.S. during the year can produce a "dual-status" year, in which you are a resident for part of the year and a nonresident for the rest. The rules for dual-status taxpayers are more restrictive than for full-year residents, so the partial-year treatment often reduces the deductions and credits available.
Holding a green card while living abroad is the classic trap. Because the card continues to define resident status, the holder remains taxable on worldwide income until the card is formally abandoned or revoked, and there are special rules for long-term residents who relinquish the card.
Students and scholars on F, J, M, or Q visas often assume their presence counts toward residency immediately, when in fact the exempt-individual rules usually keep them nonresidents during the exempt period. Once the exemption expires, they may become residents under the substantial presence test.
Spouses of U.S. citizens or residents sometimes believe marriage alone makes them residents. It does not. The statutory tests apply, though an election may allow a joint return that treats a nonresident spouse as a resident for that year.
Finally, treaty tie-breaker rules can override the domestic tests. A person who appears to be a resident under the green card or substantial presence test may nonetheless be treated as a nonresident under a treaty tie-breaker provision, and that determination requires care and proper disclosure.
How to Decide for Yourself
Start with the two statutory tests in order. Ask whether you held a green card at any point during the year; if so, you are generally a resident. If not, calculate your substantial presence using the weighted formula and check whether any exempt-individual days apply. If the math pushes you over 183 and you were present at least 31 days in the current year, you are generally a resident unless the closer connection exception or a treaty applies. If you moved to the U.S. during the year, check whether a first-year election fits your situation.
Document your calculation. Keep a day-count record, copies of visa or immigration documents, and any treaty positions you rely on, because residency determinations are a common subject of examination and the burden of supporting your position falls on you.
The answer to "am I a U.S. resident for tax purposes?" is therefore not intuitive but mechanical: green card, substantial presence, or a valid election. Get the mechanics right, and everything about your filing follows.
This article provides general educational information about U.S. tax residency rules and is not legal or tax advice. Residency determinations depend on individual facts, immigration documents, treaty provisions, and current IRS guidance, and the rules can change. Consult a qualified tax professional or the IRS for guidance specific to your situation before filing.