On an H1B visa, you are almost always a resident alien for U.S. federal tax purposes, and usually from your first full calendar year in the country. The reason is mechanical: every day you spend in the United States on an H1B counts toward the IRS’s substantial presence test, and once you cross the threshold you’re taxed the same way a U.S. citizen is, on worldwide income. The classification isn’t a choice tied to your visa type; it’s the output of a day-count formula that H1B holders can’t opt out of.
The Substantial Presence Test Decides It
The IRS uses two tests to classify a non-citizen as a resident alien or nonresident alien. You only need to pass one.1Internal Revenue Service. Determining an Individual’s Tax Residency Status The first, the green card test, doesn’t apply to H1B holders unless a green card is actually issued. The second, the substantial presence test, is the one that decides nearly every H1B case.
You meet the substantial presence test if you were physically in the U.S. for at least 31 days during the current year and at least 183 days over a three-year lookback: all your days this year, one-third of last year’s days, and one-sixth of the days two years ago.2Internal Revenue Service. Substantial Presence Test
Some visa categories can exclude their U.S. days from that count. Students on F or J visas, teachers and trainees on J or Q visas, and foreign government officials on A or G visas qualify as “exempt individuals” because those statuses contemplate a temporary educational or diplomatic stay. H1B holders get no such exclusion. The IRS is explicit that every day an H1B worker spends in the United States counts toward the test.3Internal Revenue Service. Taxation of Alien Individuals by Immigration Status – H-1b
The arithmetic is straightforward. Arrive on H1B in April and work through December and you’ve been present roughly 270 days, which by itself clears 183. Arrive later in the year and fall short, and a full second calendar year will almost certainly push you over once the lookback picks up partial credit for the arrival year.
Your First Calendar Year Is the Tricky One
The year you arrive is the only year where the answer isn’t automatic. If you meet the substantial presence test in that year, you’re a resident alien for the entire year. If you arrive late and don’t hit the threshold, you’d otherwise be a nonresident alien for the whole year. Two rules can change the outcome.
Dual-Status Year
If you become a resident alien partway through the year, you file as a dual-status taxpayer. Only U.S.-source income is taxed for the nonresident portion of the year; worldwide income is taxed for the resident portion.4Internal Revenue Service. Taxation of Dual-Status Individuals
The mechanics are awkward. If you’re a resident on December 31, you file Form 1040 with “Dual-Status Return” written across the top, and attach a Form 1040-NR labeled “Dual-Status Statement” for the nonresident portion. If you’re a nonresident on December 31, it’s reversed. Either way, you cannot claim the standard deduction ($16,100 for single filers in 2026, $32,200 for married filing jointly). You must itemize.4Internal Revenue Service. Taxation of Dual-Status Individuals
The First-Year Choice
If you don’t meet the substantial presence test in your arrival year but will meet it the following year, you can elect to be treated as a resident alien from your arrival date. This election lives in Section 7701(b) of the Internal Revenue Code.5Office of the Law Revision Counsel. 26 USC 7701 – Definitions To qualify, you must not have been a resident alien in the prior year, must meet the substantial presence test in the year after the election year, must be present for at least 31 consecutive days in the election year, and must be present for at least 75% of the days from the start of that 31-day stretch through December 31 (up to five days of absence are excused).
You make the election on your tax return, but you can’t file until you’ve met the substantial presence test in the following year, which usually means going on extension. The upside is that resident status lets you claim the standard deduction and file jointly with a spouse, benefits that can outweigh the cost of reporting worldwide income.
When a Tax Treaty Can Change the Answer
Passing the substantial presence test doesn’t always end the analysis. If your home country also considers you a tax resident under its own laws, you’re a “dual-resident taxpayer,” and the treaty between the U.S. and your home country may contain a tie-breaker clause that assigns you to one country based on where your permanent home is, where your personal and economic ties are strongest, and where you habitually live.6Internal Revenue Service. Publication 519 (2025), U.S. Tax Guide for Aliens
If the tie-breaker assigns you to the foreign country, you compute your U.S. income tax as a nonresident alien: Form 1040-NR, U.S.-source income only. You must attach Form 8833 to disclose the treaty position, and the penalty for failing to file it when required is $1,000 per occurrence.7Internal Revenue Service. Claiming Tax Treaty Benefits Note the boundary: claiming nonresident status under a treaty tie-breaker only affects how your income tax is calculated. You’re still a U.S. resident for other purposes, including counting days toward the substantial presence test in future years.
A separate exception, the closer connection exception, is available to people present fewer than 183 days in the current year who maintain a tax home in a foreign country and have a closer connection there. You claim it on Form 8840.8Internal Revenue Service. Closer Connection Exception to the Substantial Presence Test In practice, most full-time H1B workers can’t use it. If you work for a U.S. employer at a U.S. office, your tax home is in the United States, and the exception requires a foreign tax home. Filing (or having pending) an application to adjust to lawful permanent resident status disqualifies you outright.
What Changes Once You’re a Resident Alien
The classification touches most lines of your return.
Worldwide Income Becomes Taxable
Resident aliens report worldwide income: wages, interest, dividends, rental income, and capital gains from any country. Bank interest earned in your home country, a stock sale on a foreign exchange, rent from property abroad — all of it goes on your U.S. return.9Internal Revenue Service. Alien Taxation – Certain Essential Concepts Nonresident aliens, by contrast, report only U.S.-source income.10Internal Revenue Service. Taxation of Nonresident Aliens
Same Forms, Same Deductions, Same Credits as Citizens
Resident aliens file Form 1040, the same return U.S. citizens use.11Internal Revenue Service. Topic No. 851, Resident and Nonresident Aliens You can take the standard deduction, file jointly with a spouse, and claim the full range of credits available to citizens, including the child tax credit and earned income credit if you otherwise qualify. Nonresident aliens generally cannot take the standard deduction, cannot use married-filing-jointly or head-of-household status, and have limited access to credits.12Internal Revenue Service. 2025 Instructions for Form 1040-NR U.S. Nonresident Alien Income Tax Return
If your spouse is a nonresident alien, an election under IRC 6013(g) lets you treat them as a resident for the entire year so you can file jointly. The tradeoff is that your spouse’s worldwide income becomes taxable in the U.S. for as long as the election stays in effect. For couples where the spouse has little foreign income, the larger standard deduction and joint brackets usually come out ahead; where the spouse earns significantly abroad, the math can flip.
Social Security and Medicare Apply From Day One
H1B holders owe Social Security and Medicare (FICA) taxes from their first day of work. There is no exemption or phase-in period, unlike F-1 and J-1 statuses. If you changed from F-1 or J-1 to H1B, your employer must begin withholding FICA on the effective date of the status change.13Internal Revenue Service. Employers Must Withhold FICA Taxes for Aliens Who Change Visa Status to H1B
If your home country has a totalization agreement with the U.S., you may be exempt from U.S. Social Security taxes while remaining covered by your home country’s system. Agreements exist with roughly 30 countries, including Canada, the United Kingdom, Germany, Japan, South Korea, Australia, and India. Claiming the exemption requires a certificate of coverage from your home country’s social security agency.14International Programs | SSA. Totalization Agreements
Foreign Accounts Now Have to Be Reported
Once you’re a resident alien, two separate foreign-asset reporting regimes attach to you. If the combined balance of your foreign financial accounts exceeds $10,000 at any point in the year, you file an FBAR (FinCEN Form 114) with the Financial Crimes Enforcement Network.15Financial Crimes Enforcement Network. Report Foreign Bank and Financial Accounts Separately, under FATCA, you file Form 8938 with your tax return if your specified foreign financial assets exceed $50,000 on the last day of the year or $75,000 at any time during the year for a single filer in the U.S. (higher thresholds apply for joint filers).16Internal Revenue Service. Summary of FATCA Reporting for U.S. Taxpayers Neither form generates additional tax on its own, but penalties for missing them are steep.
State Residency Is a Separate Question
Federal residency status and state residency status are determined under different rules. You can be a nonresident alien federally and still owe state income tax as a state resident, or the reverse. Most income-tax states treat you as a statutory resident if you maintain a dwelling in the state and are physically present for more than half the year, commonly 183 or 184 days, though some states use different benchmarks and also look at factors like driver’s license, family location, and voter registration. Texas, Florida, Washington, and Nevada have no state income tax. If your state does tax income, check whether it follows your federal residency determination or applies its own analysis, because the two don’t always line up.