What Is Capital Gains Tax? Short- and Long-Term Rates Explained

By Markets & Investing DeskUpdated Nov 10, 2026

Capital Gains Tax
Illustration · Fintrev

Definition

Capital gains tax is the tax on the profit from selling an asset such as stock, crypto or real estate for more than you paid, with the rate set mainly by how long you held it.

Key takeaways

  • Assets held one year or less produce short-term gains taxed at your ordinary income tax rates.
  • Gains on assets held more than one year are taxed at 0%, 15% or 20%, based on taxable income and filing status.
  • Net capital losses can offset up to $3,000 of ordinary income a year, with the rest carried forward indefinitely.
  • Married couples filing jointly can exclude up to $500,000 of gain on a qualifying home sale, or $250,000 for single filers.

Capital gains tax is the tax on the profit you make when you sell a capital asset, such as stock, bonds, cryptocurrency, real estate or collectibles, for more than you paid for it. In the United States, the rate depends mainly on how long you held the asset. Gains on assets held for one year or less are short-term and taxed at your ordinary income tax rates. Gains on assets held for more than one year are long-term and taxed at 0%, 15% or 20%, depending on your taxable income and filing status. A few asset types, including collectibles and part of the gain on depreciated real estate, follow their own rules.

The tax applies only to the gain, not the sale price, and only once the gain is realized through a sale or exchange. A stock that has doubled in value but is still in your brokerage account has an unrealized gain, and no capital gains tax is due on it yet.

What Counts as a Capital Gain

A capital asset is, broadly, almost everything you own for personal use or investment. For individual investors, that includes:

  • Stocks, exchange-traded funds and mutual fund shares
  • Bonds and other debt securities
  • Digital assets such as cryptocurrencies and NFTs
  • Real estate, including your home and investment property
  • Collectibles such as art, antiques, jewelry, coins, stamps and precious metals

A capital gain arises when you dispose of one of these assets for more than its basis. Selling is the most common way, but exchanging one asset for another can also trigger a gain. Trading one cryptocurrency for another, for example, is treated as a disposal of the first coin.

Two terms do most of the work in the calculation:

  • Cost basis is generally what you paid for the asset, including purchase costs such as commissions. For real estate, it also includes the cost of capital improvements. Depreciation you deducted reduces it.
  • Amount realized is what you received from the sale, minus selling costs such as commissions or real estate agent fees.

The difference between the two is your capital gain or capital loss.

Short-Term vs. Long-Term Capital Gains

The holding period decides which set of rates applies.

Short-term capital gain Long-term capital gain
Holding period One year or less More than one year
How it is taxed As ordinary income, at your regular bracket rates At 0%, 15% or 20%, based on taxable income
Typical effect Same rate as wages and interest Lower rate than ordinary income for most taxpayers

The holding period generally starts the day after you buy the asset and includes the day you sell it. To qualify as long-term, you need to hold for more than one year, so an asset bought on March 10 of one year needs to be sold on March 11 of the following year or later. Selling on the anniversary date itself leaves the gain short-term.

Hypothetical example (assumed rates): an investor in the 24% ordinary income bracket, who also falls in the 15% long-term capital gains bracket, makes a $10,000 profit on a stock. If the stock was held for 11 months, federal tax on the gain is about $2,400. If the same profit came after 13 months, federal tax is $1,500. The difference of $900 comes entirely from the holding period.

Long-Term Capital Gains Tax Rates

Long-term gains use a separate rate schedule based on taxable income, with thresholds adjusted annually for inflation.

2025 long-term capital gains rates (by taxable income)

Filing status 0% rate 15% rate 20% rate
Single $0 to $48,350 $48,351 to $533,400 $533,401 and above
Head of household $0 to $64,750 $64,751 to $566,700 $566,701 and above
Married filing jointly and surviving spouse $0 to $96,700 $96,701 to $600,050 $600,051 and above
Married filing separately $0 to $48,350 $48,351 to $300,000 $300,001 and above

2026 long-term capital gains rates (by taxable income)

Filing status 0% rate 15% rate 20% rate
Single $0 to $49,450 $49,451 to $545,500 $545,501 and above
Head of household $0 to $66,200 $66,201 to $579,600 $579,601 and above
Married filing jointly and surviving spouse $0 to $98,900 $98,901 to $613,700 $613,701 and above
Married filing separately $0 to $49,450 $49,451 to $306,850 $306,851 and above

Qualified dividends use the same 0%, 15% and 20% schedule even though they are not capital gains. Ordinary (nonqualified) dividends are taxed as ordinary income, like short-term gains.

How Long-Term Gains Stack on Top of Ordinary Income

Capital gains do not replace your normal income tax. Your ordinary income (wages, interest, short-term gains, ordinary dividends) is taxed first at regular bracket rates. Long-term gains and qualified dividends are layered on top, and the thresholds in the tables are measured against your total taxable income, not the gain alone.

That means part of a gain can fall in the 0% band and the rest in the 15% band.

Hypothetical worked example (2025 single filer thresholds):

  • Taxable ordinary income after deductions: $40,000
  • Long-term capital gain: $20,000
  • Total taxable income: $60,000

The 0% band for a single filer runs up to $48,350. Ordinary income fills the first $40,000, so the gain occupies the range from $40,000 to $60,000.

  • $8,350 of the gain (from $40,000 up to $48,350) is taxed at 0%
  • $11,650 of the gain (from $48,350 up to $60,000) is taxed at 15%, or $1,747.50

Federal tax on the $20,000 gain is $1,747.50, an effective rate of about 8.7% on the gain. The $40,000 of ordinary income is still taxed at the regular brackets as usual. The example ignores state tax and the net investment income tax, which does not apply at this income level.

How to Calculate Capital Gains

The basic formula is:

Capital gain (or loss) = Amount realized − Adjusted cost basis

Hypothetical example: you buy 100 shares at $50 and pay a $10 commission, for a basis of $5,010. Two years later you sell all 100 shares at $80 and pay another $10 commission, for an amount realized of $7,990. Your long-term capital gain is $7,990 − $5,010 = $2,980.

Brokers report sales to you and the IRS on Form 1099-B, usually including basis for shares bought in recent years. Keep your own trade confirmations anyway: for shares transferred between brokers or bought long ago, the 1099-B may not show basis.

Netting Gains and Losses

When you have several sales in a year, you do not pay tax on each one separately. Gains and losses are netted in a set order:

  1. Add up all short-term gains and short-term losses to get a net short-term gain or loss.
  2. Add up all long-term gains and long-term losses to get a net long-term gain or loss.
  3. If one result is a gain and the other a loss, net them against each other.

The character of what remains matters. A net short-term gain is taxed as ordinary income; a net long-term gain gets the lower rates. If a long-term loss wipes out a short-term gain, it effectively saves tax at your ordinary rate.

The $3,000 Loss Limit and Carryovers

If your losses exceed your gains for the year, you can deduct up to $3,000 of the net capital loss against ordinary income ($1,500 if married filing separately). Any loss beyond that carries forward to future years with no expiration for individuals, where it first offsets future capital gains and then up to $3,000 of ordinary income each year.

Hypothetical example: an investor realizes a $5,000 gain on one stock and a $20,000 loss on another in the same year, leaving a $15,000 net capital loss. With $50,000 of other taxable income, the investor deducts $3,000 and reports $47,000. The remaining $12,000 carries forward: with no later capital gains it would be used at $3,000 per year over the next four years, and any future gains would absorb it faster.

Losses on personal-use property, such as your home or car, are not deductible.

Choosing a Cost Basis Method

If you bought shares of the same stock or fund at different times and prices, which shares you are treated as selling changes the gain. Common methods for securities include:

  • First in, first out (FIFO): the oldest shares are treated as sold first. This is the default if you do not choose another method.
  • Specific share identification: you designate exactly which lots you are selling, for example the highest-cost lots to reduce a gain, or lots held more than a year to keep it long-term. Broker options such as “last in, first out” or “highest cost” are applications of this method.
  • Average cost: available for mutual fund shares and shares in certain dividend reinvestment plans, using the average price of all shares held.

Specific identification generally has to be made at the time of sale, usually through your broker’s lot selection settings. The best choice depends on the prices of your lots, how long you have held each one, and whether you would rather realize gains or losses that year.

Assets With Special Capital Gains Rules

Collectibles

Short-term gains on collectibles (art, antiques, jewelry, precious metals, stamps, coins and similar items) are taxed as ordinary income, like any other short-term gain. Net long-term gains on collectibles are taxed at a maximum rate of 28% rather than the usual 20% top rate. Taxpayers in lower brackets pay their ordinary rate if it is below 28%.

Selling Your Home

Gains on the sale of your principal residence get a large exclusion. You can exclude up to $250,000 of gain from taxable income, or up to $500,000 if married filing jointly, provided you owned and lived in the home as your main residence for at least two of the five years before the sale. The two years do not have to be consecutive.

Hypothetical example: a single homeowner who meets the ownership and use tests buys a house for $200,000 and later sells it for $500,000. The gain is $300,000. After the $250,000 exclusion, $50,000 is a taxable capital gain, long-term if the home was owned more than a year.

The cost of significant improvements, such as a new roof or an addition, is generally added to your basis, which reduces the gain. Routine repairs and maintenance are not.

Investment Real Estate and Depreciation Recapture

Owners of rental and other investment property can deduct depreciation each year to account for wear and tear on the building. Depreciation reduces your basis, so it increases the gain when you sell.

The portion of the gain created by depreciation on real estate (known as unrecaptured Section 1250 gain) is taxed at a maximum rate of 25%. The rest of the gain receives the normal long-term rates.

Hypothetical example:

  • You buy a rental building for $100,000 and claim $5,000 of depreciation, reducing your basis to $95,000.
  • You later sell for $110,000, a total gain of $15,000.
  • $5,000 of that gain reflects depreciation and is taxed at up to 25%.
  • The remaining $10,000 is taxed at 0%, 15% or 20%, depending on your income.

The Net Investment Income Tax

Higher-income taxpayers may owe an additional 3.8% net investment income tax (NIIT) on investment income, including capital gains, dividends, interest and rental income. It applies to the lesser of your net investment income or the amount by which your modified adjusted gross income (MAGI) exceeds these thresholds:

  • $200,000 for single filers and heads of household
  • $250,000 for married couples filing jointly and surviving spouses
  • $125,000 for married couples filing separately

The NIIT is added on top of the capital gains rate. A taxpayer in the 20% long-term bracket who owes the NIIT pays a combined federal rate of 23.8% on the affected gains.

When You Owe Capital Gains Tax and How It Is Reported

Capital gains tax is owed for the tax year in which the sale or exchange occurs. Moving money between accounts does not trigger tax; selling the shares does.

One exception catches many fund investors: mutual funds and some ETFs pass on capital gains distributions when the fund itself sells holdings at a profit. Those distributions are taxable to you in the year paid, even if you never sold a share and reinvested the distribution.

Sales are reported on Form 8949 and summarized on Schedule D of Form 1040. If a large gain means too little tax was withheld or paid during the year, the IRS may expect quarterly estimated tax payments, and an underpayment penalty can apply even if you pay the full amount by the filing deadline.

Harvest Losses

Tax-loss harvesting means selling investments that are below their basis to realize losses that offset gains elsewhere in your portfolio, often in a year-end review. Because of the netting order, losses are most valuable against short-term gains, which would otherwise be taxed at ordinary rates.

Avoid the Wash Sale Rule

A loss is disallowed if you buy the same or a substantially identical security within 30 days before or after the sale that created the loss. The rule covers a 61-day window around the sale and also applies if a spouse or an account you control (including an IRA) makes the purchase. The disallowed loss is added to the basis of the replacement shares, so it is deferred rather than lost, except when the replacement is bought inside an IRA. Investors who want to stay invested often buy a similar but not substantially identical fund, or wait more than 30 days to repurchase.

Use Tax-Advantaged Accounts

Inside a 401(k), traditional IRA or similar plan, you can buy and sell investments without paying capital gains tax on each trade. With traditional accounts, tax is deferred until withdrawal, and withdrawals are taxed as ordinary income regardless of whether the growth came from capital gains. Qualified withdrawals from a Roth IRA or Roth 401(k) are tax-free. The tradeoff is reduced access: early withdrawals can bring taxes and penalties.

Time Sales for Lower-Income Years

Because the 0% and 15% bands depend on total taxable income, the same gain can cost less in a year when your other income is low, such as after retirement, during a career break or in a year with large deductions. Conversely, a large gain realized while working can push income above a threshold and turn a potential 0% gain into a taxable one.

What Capital Gains Tax Is Often Confused With

  • Ordinary income tax. Short-term gains are taxed at ordinary rates but remain capital gains for netting purposes. Wages, interest and ordinary dividends are ordinary income, not capital gains.
  • Dividend tax. Dividends are income from holding a stock, not profit from selling it. Qualified dividends borrow the long-term capital gains rates; ordinary dividends do not.
  • Tax on the sale price. Selling a $50,000 position bought for $45,000 creates a $5,000 gain, not $50,000 of taxable income.
  • Depreciation recapture and the NIIT. Both can apply to the same sale as capital gains tax, but they are separate calculations with their own rates and thresholds.
  • CGT in other countries. Countries such as the UK, Australia and Canada set their own rates, allowances and holding rules. The U.S. schedules here apply only to U.S. federal tax.

Limitations to Keep in Mind

Beyond the headline 0%, 15% and 20% rates, the NIIT can add 3.8%, collectibles can reach 28%, depreciation-related real estate gains can reach 25%, and most states tax capital gains as regular income on top of the federal tax.

Because gains raise your adjusted gross income, a large sale can affect other income-based items, such as whether you cross the NIIT threshold. The thresholds change each year, so use the table for the year you sell.

Finally, tax rules should not be the only reason to hold or sell. Waiting for long-term treatment exposes you to price changes in the meantime, and a position that falls further while you wait can cost more than the tax you were trying to save.

FAQs

Do inherited assets get taxed when sold?

Generally, the heir's basis is "stepped up" to the asset's fair market value on the date of the original owner's death, so gains that built up during the owner's lifetime are not taxed. If you sell soon after inheriting, the taxable gain is often small. Inherited assets are also treated as long-term regardless of how long you held them.

What basis do I use for gifted stock?

For a gift, you generally take over the giver's original basis and holding period (called carryover basis). If you later sell at a gain, you are taxed on the appreciation that occurred while the giver owned it as well as during your own ownership. Special rules apply if the asset was worth less than the giver's basis at the time of the gift.

Is cryptocurrency subject to capital gains tax?

Yes. Digital assets are treated as property, so selling crypto for dollars, trading one coin for another or spending it on goods can trigger a capital gain or loss, measured against your basis in those units. The same holding period rules apply.

Do I pay capital gains tax if I reinvest the proceeds?

Yes, for ordinary brokerage accounts. Reinvesting sale proceeds in another stock or fund does not defer the tax on the gain you realized. Deferral happens only in specific structures, such as trades inside a retirement account.

The Bottom Line

Anyone selling stocks, funds, crypto, a home or rental property needs to know how holding periods, loss netting and special rules shape the tax bill. Holding past one year, harvesting losses without triggering the wash sale rule, using tax-advantaged accounts and timing sales for low-income years can all lower the bill legally. Tax savings should still be weighed against the risk that a position loses value while you wait.

About this page

Written by Markets & Investing Desk

The Markets & Investing Desk covers investing guides, the financial dictionary, companies, people, economics and market data.

Published
Last updated

Spotted an error? Tell the editors. This page is general information, not financial advice.