Substantial presence test · 2026

Am I a Resident Alien?

For F-1, J-1, M-1 and Q-1 visitors. Enter the year you first came and your days in the US: your exempt years are left out for you, and you see which tax return is yours.

You are a

The first calendar year you were in the US as an F, J, M or Q student, teacher or trainee, even for part of it, however long ago.

Days in the US

Example: a student who first came in 2022

You are a nonresident alien for 2026

Exempt year 5 of 5

2026 is your 5th of 5 exempt years. If you were in F, J, M or Q status all year, none of its days count and you stay a nonresident alien. Days on another visa, such as H-1B, do count. Your days start to count in 2027.

  1. File Form 8843, even with no income: it is what keeps your days from counting. Check what goes with it.
  2. File Form 1040-NR if you had US income, such as a campus job, CPT, OPT or a taxable scholarship.
  3. No Social Security or Medicare tax on pay your visa allows. If your W-2 shows some, see what comes back.
File your 1040-NR and 8843 free

Free, once the final 2026 forms are published, for W-2, 1099-INT, 1099-DIV and 1099-MISC income, and Form 1042-S scholarships and treaty-exempt pay.

Assumes you were in the US for part of every calendar year since your first. Not covered: the closer connection exception (Form 8840), medical-condition days and treaty tie-breaker rules. This is information, not tax advice. Checked against IRS sources on . How we research.

Is an F-1 student a resident alien?

Not in their first five calendar years on an F, J, M or Q visa. F-1, J-1, M-1 and Q-1 students are exempt individuals for five calendar years, so their days in the US do not count toward the substantial presence test, and they file as nonresident aliens.

From the sixth calendar year the days count. A student who first came in 2021 and is here all of 2026 counts 365 days, all from 2026 since the two years before were exempt, and is a resident alien for 2026.

How does the substantial presence test work?

You are a resident alien for 2026 if you meet both:

  • At least 31 days in the US in 2026, and
  • At least 183 days counting every day of 2026, a third of the days of 2025 and a sixth of the days of 2024.

Days in an exempt year count as none. The IRS's own example: 120 days in each of three years counts 120 + 40 + 20 = 180, which is short of 183.

Which years are exempt?

  • Students (F-1, M-1, and J-1 or Q-1 as a student): any part of five calendar years. Earlier years on an F, J, M or Q visa count toward the five.
  • Teachers, researchers and trainees (J-1 or Q-1, not a student): two calendar years, because they are not exempt if they were exempt in any part of 2 of the 6 years before.

What changes when you become a resident alien?

You file Form 1040 instead of Form 1040-NR, you get the standard deduction if you are a resident for the whole year, and Social Security and Medicare tax applies to most of your pay. See the sixth-year guide and resident vs nonresident alien tax.

Sources

FAQ

About your residency.

The substantial presence test guide
Is an F-1 student a resident alien or a nonresident alien?

A nonresident alien, for their first five calendar years on an F, J, M or Q visa. F, J, M and Q students are exempt individuals for five calendar years, so their days in the US do not count toward the substantial presence test. From the sixth calendar year the days count, and a student who stays most of the year becomes a resident alien.

When does an F-1 student become a resident alien for tax purposes?

Usually in their sixth calendar year in the US, once they have been in the US 183 days that year. Any part of a calendar year counts as a whole year, so a student who arrived in August 2021 has used up 2021 to 2025 and counts days from January 1, 2026. A student past five years can keep excluding days only by showing the IRS, in a statement with Form 8843, that they do not intend to live in the US permanently, among other conditions.

Do OPT and STEM OPT years count toward the five years?

Yes. OPT and STEM OPT are F-1 status, so those calendar years are F-1 student years. That is why STEM OPT often reaches the sixth year: a student who came for a two-year master's and then took three years of OPT and STEM OPT is in their sixth calendar year by the end.

How long are J-1 researchers and scholars nonresident aliens?

Usually two calendar years. A J-1 or Q-1 teacher, researcher or trainee who is not a student cannot exclude their days if they were exempt as a teacher, trainee or student in any part of 2 of the 6 calendar years before. Years as a student count toward the two.

What counts as a day in the US?

Any day you were physically in the US, even for part of it. The test counts every day of 2026, a third of the days of 2025 and a sixth of the days of 2024. You meet it with at least 31 days in 2026 and 183 in all, leaving out your exempt years.

Do I file Form 8843 if I had no income?

Yes. Every exempt individual files Form 8843 for each year, income or not. It needs no Social Security number or ITIN if you file it alone. If you had US income, it goes with your Form 1040-NR.

File as a Nonresident, Free

F1TaxReturn counts your exempt years from your travel dates and prepares Form 1040-NR and Form 8843 for nonresident students. The federal return is free, once the final 2026 forms are published.