← cpavalidated.com

Substantial Presence Test Calculator

IRC Section 7701(b)(3)  •  U.S. Tax Residency Analysis  •  Test years 2019-2030
IRC §7701(b)(3)Treas. Reg. 301.7701(b)Form 1040-NR2019 - 2030
1

Settings

The test uses this year plus the two preceding calendar years (IRC §7701(b)(3)(A)(ii)).
Method B splits trips across calendar years and never double-counts overlapping dates.
2

Enter U.S. Days (Method A)

f(Current Year × 1) + (Prior Year × 1/3) + (Two Years Prior × 1/6) ≥ 183 weighted days, and at least 31 days in the current year
YearWeightDays in U.S.
Enter the total number of days physically present in the United States for each year. A day counts if you were present in the United States at any time during that day, including days of arrival and departure (IRC §7701(b)(7)(A)). Enter the days before any exclusions; excluded days are entered in step 3.
Description Arrival Departure Days Year
Enter each stay in the U.S. Both the arrival and departure dates count. Trips that span a year-end are split by calendar year automatically, and overlapping dates are counted once. Only the test year and the two preceding years are used.
3

Days Not Counted (Optional - Any of the Three Years)

Days that are not counted as presentCurrentPriorTwo prior
Exempt individual days (student, teacher or trainee, foreign government-related, charity sports event) - IRC §7701(b)(3)(D)(i), (b)(5)
Medical condition days (arose while in the U.S.) - IRC §7701(b)(3)(D)(ii)
Canada / Mexico commuter days - IRC §7701(b)(7)(B)
Transit days (in the U.S. under 24 hours between two foreign points) - IRC §7701(b)(7)(C)
Foreign vessel crew member days - IRC §7701(b)(7)(D)
NATO visa days (member of a force or civilian component) - Form 8840 instructions
These days are removed from each year's count before weighting. Exempt-individual and medical-condition days require Form 8843; students may be exempt for 5 calendar years, and teachers and trainees are limited to 2 of the preceding 6 years (IRC §7701(b)(5)(E)). Excluded days cannot exceed the days present that year.
4

Result

△

SPT Not Met - Nonresident Alien

Enter your U.S. presence data above to calculate.

0.00
Weighted Total
0
Current Year Days Counted
183
Weighted Days Short of 183
Weighted Day Count0 / 183 days
YearDays in U.S.Not CountedDays CountedMultiplierWeighted Days
Total----0.00
Current-Year Days That Trigger the SPT
-
counted days needed in the current year
Maximum Safe Current-Year Days
-
most counted days without meeting the SPT
Assumptions & sources
RuleValueStatusCitation
Minimum days in the current year31StatutoryIRC §7701(b)(3)(A)(i)
Weighted threshold183 days; weights 1, 1/3, 1/6StatutoryIRC §7701(b)(3)(A)(ii)
What counts as a day of presencePhysically present at any time during the dayStatutoryIRC §7701(b)(7)(A)
Days not countedExempt individual, medical condition, Canada or Mexico commuter, transit under 24 hours, foreign vessel crew, NATO visaStatutory / Form instructionsIRC §7701(b)(3)(D), (b)(5), (b)(7)(B)-(D); Form 8840 instructions
Closer connection exceptionFewer than 183 days in the current year, foreign tax home, closer connection, no green card stepsStatutoryIRC §7701(b)(3)(B), (C); Treas. Reg. §301.7701(b)-2; Form 8840
Year dependenceNone. The rule is the same for every test year, so no inflation or projection is used.StatutoryIRC §7701(b)(3)
Last verified: October 29, 2026. No projected figures are used on this page; every rule above is fixed by statute.
Related Tools
Closer Connection ExceptionForm 8840 · IRC §7701(b)(3)(B) FBAR & Form 893831 USC 5314 · IRC §6038D Pre-Immigration PlanningBefore your green card · IRC §7701(b) Tax Estimator 2026Federal + all 50 states · IRC §1
Calculator Disclaimer: This calculator provides estimates only. Results depend on inputs, facts, and assumptions. Always verify against current primary authority and consult a tax professional before filing or acting on results.
tk.cpa AI Lab
Mission Privacy tk.cpa
Nothing on this page constitutes legal, tax, accounting, or professional advice, and no professional relationship is created by your use of this website. CPA Validated is an educational website for information purposes only. Information should be verified against current primary authority, including the Internal Revenue Code, Treasury regulations, IRS guidance, and applicable state or local law, before being relied upon or acted on. Calculator outputs are estimates only and may be incomplete or inaccurate depending on the facts, assumptions, and inputs used. CPA Inc. and tk.cpa disclaim liability to the fullest extent permitted by law. Full disclaimer: cpavalidated.com/disclaimer.html