All field notes

    The substantial presence test in 2026: formula, exceptions, forms

    The IRS counts this year's days in full, last year's at one third and the year before at one sixth. How the 183-day total works, which days drop out and when Form 8840 keeps a person nonresident.

    By · 6 min read

    The substantial presence test makes a person who is not a US citizen a US tax resident for a calendar year when they spend at least 31 days in the United States that year and at least 183 days over three years, counting every day this year, one third of last year's days and one sixth of the year before.

    What is the substantial presence test

    The substantial presence test is the day-count route to US tax residency for anyone who is not a US citizen. It sits in Internal Revenue Code section 7701(b), is in force, and the IRS explains it in Publication 519 (2025), the US Tax Guide for Aliens.

    The income tax rates a resident then pays are in our US tax guide, and the day count is the first question in any tax residency review involving the United States. The 183-day condition weights three years.

    • Current year · every day of presence counts in full
    • First year before · one third of the days count
    • Second year before · one sixth of the days count

    How do you calculate the 183 days

    Add the current year's days, one third of last year's and one sixth of the year before. The IRS example: 120 days in each of 2023, 2024 and 2025 gives 120 plus 40 plus 20, or 180, so no residency for 2025.

    An illustration for 2026: a consultant spends 150 days in the US in 2026 and 120 in each of 2025 and 2024. The count is 150 plus 40 plus 20, or 210, so the consultant meets the test for 2026. Because 150 is fewer than 183, the closer connection exception below stays open.

    At 121 days every year the total is 181.5. At 122 days every year it reaches exactly 183 and meets the test.

    Which days do not count

    A day counts when a person is in the United States at any time during it, with five exclusions.

    • Regular commuters · from a home in Canada or Mexico, commuting on more than 75 percent of workdays
    • Transit · under 24 hours between two places outside the US
    • Crew members · of a foreign vessel
    • Medical condition · unable to leave because of a condition that arose in the US
    • Exempt individuals · the categories below

    The IRS states that US territories and US airspace do not count as the United States for the test.

    Who is an exempt individual

    An exempt individual is a person whose days are excluded because of their visa status; the IRS notes that the term does not mean exempt from US tax.

    • Foreign government-related individuals · A or G visas, except A-3 and G-5 holders
    • Teachers and trainees · J or Q visas, substantially complying with the visa
    • Students · F, J, M or Q visas, substantially complying with the visa
    • Professional athletes · temporarily present to compete in a charitable sports event

    Publication 519 caps the exemption: teachers and trainees lose it after any part of 2 of the 6 preceding years as exempt, students after any part of more than 5 calendar years, unless further conditions are met. Excluded days are reported on Form 8843.

    What is the closer connection exception

    The closer connection exception treats a person who meets the test as a nonresident when four IRS conditions hold.

    • Presence in the US on fewer than 183 days during the year
    • A tax home in one foreign country for the entire year
    • A closer connection to that country than to the United States
    • No steps taken toward a green card and no application pending

    The IRS weighs where the permanent home, family and belongings are, where the person votes and holds a driving licence, and which forms they sign, such as Form W-9 or Form W-8BEN.

    The claim is made on Form 8840. Publication 519 states that a person who files it late cannot claim the exception, unless they show by clear and convincing evidence that they took reasonable steps to comply.

    When is Form 8840 due

    Form 8840 is due on the Form 1040-NR due date. For the 2025 calendar year, Publication 519 sets that date at 15 April 2026 for a person with US wages subject to withholding and at 15 June 2026 for everyone else.

    Heed's reading: the 183 in the test is a weighted three-year total, so a person under 183 days in every single year can still become resident, and the closer connection exception then rests on one form filed on time.

    How does a tax treaty change the answer

    A treaty tie-breaker can override the test for a dual resident. Publication 519 states that such a person figures US tax as a nonresident on Form 1040-NR with Form 8833 attached, and that in certain instances the claim can trigger the section 877A expatriation tax. Our 183-day rule comparison sets the US test beside the UK, Spain and the UAE.

    When does US residency start and end

    Residency generally starts on the first day of presence in the year the test is met. Publication 519 lets up to 10 earlier days with a closer connection abroad be left out of that date, and lets residency end on the last day of presence when the tax home sat abroad for the rest of the year.

    Heed monitors international tax law changes across every jurisdiction we track and sends personalised alerts before they affect your situation.

    FAQ

    Frequently asked questions

    How many days can you stay in the US without becoming a tax resident?

    Under the substantial presence test, 121 days every year keeps the weighted total at 181.5, under 183. At 122 days a year the total reaches 183 and the test is met. Fewer than 31 days in a year never meets it. Exempt days and the closer connection exception can change the result.

    Do partial days count toward the substantial presence test?

    Yes. The IRS treats a person as present on any day they are physically in the United States at any time during that day. The exclusions are transit of less than 24 hours between two foreign points, regular commuting from Canada or Mexico, crew days on a foreign vessel and days kept in by a medical condition.

    What is Form 8840?

    Form 8840 is the closer connection exception statement. A person who meets the substantial presence test but was present on fewer than 183 days in the year files it to be treated as a nonresident. It is due on the Form 1040-NR due date, and Publication 519 states that a late form generally loses the exception.

    Do F-1 students count days for the substantial presence test?

    Students on F, J, M or Q visas who substantially comply with their visa are exempt individuals, so their days are excluded. Publication 519 limits this: a student exempt for any part of more than 5 calendar years loses the exclusion unless further conditions are met. Excluded days are reported on Form 8843.

    Can a tax treaty override the substantial presence test?

    Yes, for a dual resident. Publication 519 states that the US residency rules do not override treaty definitions of residency. A person treated as resident of the other country under the treaty tie-breaker figures US tax as a nonresident, files Form 1040-NR and attaches Form 8833 to disclose the position.

    Sources

    Official sources cited

    Keep reading

    Related field notes