| Item | Value |
|---|---|
| As of | November 3, 2026 |
| Last checked | November 3, 2026 |
| Next scheduled quarterly check | December 5, 2026 |
When you sell a US-listed stock or ETF at a gain, does the United States tax that gain? The answer depends first on your status (Lesson 490). This lesson sets out the general US position for nonresident aliens, and for US persons the holding-period rule, the 2026 rate brackets for long-term gains, the net investment income tax and the limit on deducting losses.
The page covers US federal income tax only. A non-US person's gain may still be taxed by the country where that person lives, and US persons may also owe state tax; neither is covered here.
1. At a glance: status first, then holding period
This lesson is general information about US rules as of November 3, 2026. It is not tax, legal or investment advice, and the rules of your country may also apply.
- Nonresident alien in the United States for less than 183 days during the tax year: US-source capital gains that are not effectively connected with a US trade or business are exempt from US tax.
- Nonresident alien present 183 days or more during the tax year: the net US-source capital gain is taxed at 30%, or a lower treaty rate.
- US person: a gain on an asset held more than 1 year is long-term and taxed at 0%, 15% or 20%; a short-term gain is taxed at ordinary income rates.
- US person with a net capital loss: up to $3,000 a year ($1,500 if married filing separately) reduces other income; the rest carries forward.
- Within the scope of this lesson, no change is pending.
2. Rules in force now: who is taxed, at which rate
| Rule | Current rule | Applies to | Basis |
|---|---|---|---|
| Nonresident alien, under 183 days | Capital gains from US sources that are not effectively connected with a US trade or business are tax exempt if you were in the United States for less than 183 days during the tax year | IRS edition for 2025 returns | IRS Publication 519, chapter 4 |
| Nonresident alien, 183 days or more | Net gain from sales of capital assets is taxed at a 30% (or lower treaty) rate; net gain is US-source capital gains minus US-source capital losses | IRS edition for 2025 returns | IRS Publication 519, chapter 4 |
| No withholding on gains | A withholding agent generally does not need to withhold on gain from the sale of personal property, because it is not FDAP income | IRS edition for 2026 | IRS Publication 515 |
| Holding period | Long-term if held more than 1 year; count from the day after you acquired the asset and include the day you disposed of it; for listed securities, use trade dates, not settlement dates | Editions for 2025 returns | Instructions for Form 8949 (2025); IRS Publication 550, chapter 4 |
| Long-term rates for 2026 | 0% up to taxable income of $49,450 (single), $98,900 (married filing jointly), $66,200 (head of household); 15% up to $545,500, $613,700 and $579,600; 20% above | Tax year 2026 | Rev. Proc. 2025-32, section 4.03 |
| Short-term gains | Net short-term capital gains are taxed as ordinary income at graduated rates | Current IRS page | IRS Topic no. 409 |
| Net investment income tax | 3.8% on the lesser of net investment income or modified adjusted gross income above $200,000 (single), $250,000 (married filing jointly) or $125,000 (married filing separately) | Current IRS page | IRS Topic no. 559 |
| Loss limit | Excess capital loss reduces other income by up to $3,000 ($1,500 married filing separately); the rest carries forward to later years | Current IRS page | IRS Topic no. 409 |
The IRS warns that the 183-day rule for capital gains bears no relation to the 183-day count of the substantial presence test (Lesson 490). A nonresident alien who reports gains under the 183-day rule does so on Schedule NEC of Form 1040-NR (Lesson 500). For that computation, Publication 519 says the cost and selling price of a sale made in foreign currency are expressed in US dollars at the exchange rate on the purchase date and on the sale date.
3. Pending changes
As of November 3, 2026, no change within the scope of this page is pending. The 2027 inflation-adjusted brackets had not been published in the IRS news releases of October 2026; the next quarterly check looks for them (Lesson 507).
4. Worked example: one set of trades, two investors
Assumptions: two hypothetical investors make the same three sales in 2026 through a US broker. Lot A, an index ETF bought in 2024, is sold for a gain of $4,000. Lot B, a stock bought on January 12, 2026 and sold on October 1, 2026, is sold for a loss of $1,500. Lot C, a stock bought and sold within 2026, is sold for a gain of $500.
Morgan is a US person. Lot A was held more than 1 year, so its $4,000 gain is long-term. Lots B and C are short-term: the net short-term result is 500 − 1,500 = −$1,000. That short-term loss reduces the long-term gain: the net capital gain is 4,000 − 1,000 = $3,000. If Morgan's taxable income falls in the 15% bracket for 2026, the federal tax on it is 3,000 × 15% = $450.

Sam is a nonresident alien who spent 140 days in the United States in 2026. The gains are from US sources but not effectively connected with a US trade or business, and Sam was present less than 183 days. Under Publication 519, the gains are exempt from US tax. Under Publication 515, the broker generally does not withhold on gains; Sam's Form W-8BEN on file documents the foreign status (Lesson 506). Now suppose Sam had been present 190 days but stayed a nonresident alien, which the IRS describes for exempt individuals such as certain students. The net US-source gain, 4,000 + 500 − 1,500 = $3,000, would then be taxed at 30%, or 3,000 × 30% = $900, unless a treaty gives a lower rate.
5. Common mistakes
- Assuming a US-listed stock makes every gain taxable in the United States. For a nonresident alien present less than 183 days, US-source capital gains that are not effectively connected are exempt from US tax.
- Mixing up the two 183-day rules. The capital gains rule counts days in the tax year only; the substantial presence test adds weighted days of two earlier years.
- Counting the holding period from the settlement date. For listed securities, it begins the day after the trade date of the purchase and ends on the trade date of the sale.
- Applying the long-term rate to every gain. A short-term gain is taxed at ordinary income rates.
- Deducting a whole capital loss in one year. A US person deducts at most $3,000 a year ($1,500 married filing separately) against other income and carries the rest forward.
- Forgetting the country where you live. The US exemption for a nonresident alien does not say anything about tax in your own country.
6. Official sources to check
- Publication 519 (2025), U.S. Tax Guide for Aliens (IRS, chapter 4, Sales or Exchanges of Capital Assets, checked November 3, 2026)
- Publication 515 (2026), Withholding of Tax on Nonresident Aliens and Foreign Entities (IRS, Gains, checked November 3, 2026)
- Publication 550 (2025), Investment Income and Expenses (IRS, chapter 4, Holding Period, checked November 3, 2026)
- Instructions for Form 8949 (2025) (IRS, short-term or long-term, checked November 3, 2026)
- Revenue Procedure 2025-32 (IRS, section 4.03, Maximum Capital Gains Rate, October 9, 2025, checked November 3, 2026)
- Topic no. 409, Capital gains and losses (IRS, checked November 3, 2026)
- Topic no. 559, Net investment income tax (IRS, checked November 3, 2026)
- The taxation of capital gains of nonresident students, scholars and employees of foreign governments (IRS international taxpayers page, checked November 3, 2026)
- News releases for current month (IRS newsroom, October 2026 list, checked November 3, 2026)
7. Change log
| Date | Change | Basis |
|---|---|---|
| November 3, 2026 | First written (English edition, US rules) | Section 6 sources |
