Tax learning center

Resident or nonresident alien for tax purposes

If you're not a U.S. citizen, the IRS puts you in one of two groups for taxes, and that decides which form you file and what income is taxed.

At a glance

Tax residency is not immigration status

"Resident alien" and "nonresident alien" are tax terms. They decide how you file a U.S. tax return and nothing else. They don't change or prove any immigration status.

The two tests

You're a resident alien for tax purposes if you meet either test:

Some days don't count. Students on F, J, M or Q visas usually don't count days for their first five calendar years, and teachers and trainees on J or Q visas usually don't count days unless they were already exempt in 2 of the 6 years before. Certain other people, such as foreign government employees, are also exempt. Someone under 183 days this year may also be able to claim a closer connection to another country.

What each group files

Dual-status years

The year you arrive or leave, you can be a nonresident for part of the year and a resident for the rest. That's a dual-status year, with special rules: generally no joint return and no standard deduction, unless you make one of the elections below.

Married to a nonresident

Some returns get referred out. We prepare resident returns and straightforward dual-status and joint-election returns. Some nonresident and tax-treaty returns need a specialist, and we'll refer you to one. We don't give legal or immigration advice.

Questions about your situation?

Book a free 15-minute call. Year-round help from the same team, and you can call us when an IRS letter shows up in July.

Free 15-minute callNot ready yet? Get a reminder in January

Official sources: IRS Publication 519 (U.S. tax guide for aliens) ↗ · IRS: Substantial presence test ↗ · IRS Publication 501 (filing status) ↗

Updated October 2026 for 2026 returns filed in 2027. General information only, not tax advice for your situation. Rules can change; your situation is confirmed when we prepare your return.

More guides: