Capital Gains Tax: What It Is & How It Works

Updated: May 09, 2022Written By: Kent ThuneReviewed By:

Capital gains tax is a tax owed on the profits from the sale of an investment asset, such as a stock, bond, mutual fund, ETF, a business, or real estate. The amount of tax owed on the gain depends primarily on whether it was a long-term holding or a short-term holding.

Hands holding documents with title capital gains tax CGT.
designer491/iStock via Getty Images

2022 Capital Gains Tax

The current capital gains tax for 2022 is 0%, 15%, or 20% for most assets held more than a year, also known as the long-term capital gains rate. For short-term capital gains, which is for most assets held less than one year, the cap gains tax rate is the same as the ordinary income tax rates, which range from 0% up to 37%, as set by the IRS.

Long-Term Capital Gains Tax

Long-term capital gains tax (LTCG) is the tax owed on the profits from the sale of an investment asset held for more than a year. The long-term capital gains tax rate can be 0%, 15%, or 20%, depending on various factors, such as income level and marital status.

Long-Term Capital Gains Tax Rates for 2022

Filing Status 0% LTCG Tax Income Level 15% LTCG Tax Income Level 20% LTCG Tax Income Level
Single Up to $41,675 $41,676 - $459,750 Over $459,751
Head of Household Up to $55,800 $55,801 - $488,500 Over $488,501
Married Filing Jointly Up to $83,350 $83,351 - $517,200 Over $517,201
Married Filing Separately Up to $41,675 $41,676 - $258,600 Over $258,601

Short-Term Capital Gains Tax

Short-term capital gains tax is the tax owed on profits from the sale of an investment asset that was held for one year or less. The short-term capital gains tax rate is equal to the ordinary income tax rate. For example, if an investor's top income tax bracket is 22%, their short-term capital gains tax will be 22%.

How To Calculate Capital Gains Tax

A simplified capital gains tax calculation is to multiply the amount of gain by the applicable tax rate.

Capital Gains Tax = Amount of Gain x Applicable Tax Rate

The capital gain is the difference between sale proceeds and the original cost or purchase price of an investment, which is called the cost basis. To determine the long-term capital gain rate, investors need to know the holding period. Here's how to calculate capital gains tax:

Step 1: Determine Cost Basis

This is generally the purchase price, plus any commissions or fees paid in association with the purchase.

Step 2: Determine the Realized Amount

This is the sale price of the investment, minus commissions or fees paid in the sale.

Step 3: Subtract Cost Basis from Realized Amount

The investor subtracts what they paid for the investment from what they sold it for. This will calculate your investment's capital gain.

Step 4: Determine Tax Rate to Apply to the Capital Gain

For an investment held for more than one year, an investor will apply the long-term capital gains rate (0%, 15%, or 20%). For an investment held for one year or less, an investor would apply the short-term capital gains rate, which is the same as their ordinary tax rate.

Calculating Capital Gains Tax Rate Example

For example, if an investor bought shares of a stock two years ago at a cost of $10,000, and then sold all of the shares at a value of $12,000, the result is a realized long-term capital gain of $2,000. If the long-term capital gains tax rate is 15%, the tax on this would be $300 (2,000 x 0.15).

If an investor's taxes are relatively simple they may be able to use's capital gains tax calculator to estimate the taxes owed.

Important: Investors don't "realize" a gain or a loss unless they sell an investment. For example, if an investor's $10,000 original investment in a stock grows to $12,000, and they continue holding the shares, the $2,000 gain is not a realized gain. Instead, the investor has an "unrealized" gain because they haven't sold any shares yet. But if the investor sells the shares for $12,000, they will owe capital gains tax on the $2,000 realized gain.

How Dividends Are Taxed

In addition to capital gains tax, investors may also be taxed on dividends paid to them. Dividends are taxed as either ordinary income or as qualified dividends, which are taxed at the long-term capital gains tax rate. To establish their dividend tax rate, investors need to distinguish between ordinary dividends and qualified dividends.

  • Ordinary dividend tax: Taxed at an individual's regular federal income tax rate, ordinary dividends are the most common form of dividend, which are paid out as a form of income to shareholders.
  • Qualified dividend tax: Taxed at the long-term capital gains tax rate, qualified dividends are generally those that are issued by a U.S. corporation traded on a major U.S. stock exchange. As well the stock must be held at least 60 days out of a 121-day holding period.

Tip: A dividend from a common stock, preferred stock, or a mutual fund is typically an ordinary dividend, unless the paying corporation or mutual fund indicates otherwise on Form 1099-DIV.

Avoid Capital Gains Tax on Stocks

Fortunately, there are multiple strategies to avoid capital gains tax on stocks, as well as other investment types, such as mutual funds and exchange-traded funds. And when an investor can't completely avoid capital gains tax, they can at least reduce or minimize the tax hit. Below are some examples of simple tax-efficient investing strategies.

1. Invest In a Tax-Advantaged Retirement Account

Realized capital gains resulting from the sale of stocks and other investments held in tax-advantaged accounts, such as IRAs and 401k plans, are not subject to capital gains tax. Traditional (pre-tax) contributions to IRAs and 401ks are taxed when withdrawals are made.

2. Use Tax Loss Harvesting

An investor can "harvest" capital losses to offset capital gains. The investor would only owe taxes on the net gain. For example, if an investor sold shares of a stock and realized a $2,000 loss and sold shares of a different stock and realized a $3,000 gain, they would only pay capital gains tax on the net gain of $1,000.

3. Plan to Sell over Multiple Years

Capital gains taxes are owed for the tax year in which the gains are realized. Some capital gains can be large enough to push an individual into a higher tax bracket. To minimize capital gains tax on stocks, the investor can sell shares over time, preferably over multiple years, rather than all at once.

4. Strategize Timing for 0% Rate

If an investor's income is low or zero, they could qualify for the 0% long-term capital gains rate. For this reason, it can make sense for an investor to sell profitable investments at retirement, or another time when the investor may be taxed at a lower rate.

5. Hold the Investment

If an investor doesn't sell an investment, they won't realize a gain; therefore, no capital gains tax would be due. Some people choose to hold certain investments for their entire lives, with the plan of passing them along to beneficiaries.

Important: If an investor holds an investment until death, the beneficiaries of the investor's estate can receive what's called a "step up" in cost basis. This eliminates the capital gain that occurred between the original purchase and the date of death. If the investor's beneficiaries later sell the investment, they would only owe capital gains tax on any realized gains above the stepped up basis.

Capital Loss Carryover

If an investor's capital losses exceed capital gains for a particular period, they can "carry over" the excess loss into later years. The capital loss carryover limit is $3,000 per year. If an investor doesn't have any capital gains during a given year, they can use the $3,000 carryover to reduce taxable income.

Bottom Line

Investors who have taxable accounts are wise to know the tax on capital gains, how LTCG tax is calculated, the current capital gains tax rates, and the differences between long-term vs short-term capital gains. With knowledge about capital gains taxes and rates, investors may potentially keep more of their returns.


  • Unless an investor is required to make quarterly estimated tax payments, capital gains tax is due by the regular tax filing date for the year in which the capital gain was realized. For example, if an investor realizes a capital gain this calendar year, they'll generally owe capital gains tax by April 15 next year.

  • Capital gains that are realized during a given tax year cannot generally be spread over multiple years. However, an investor can choose to sell their investment in pieces over the course of several years, which would then spread the capital gains tax over that time frame.

  • To discourage investors from selling securities at a loss just to claim a tax benefit, the IRS implemented the wash rule. A wash sale occurs if an investor sells a security at a loss, then purchase the same security, or a "substantially identical" security within 30 days.

  • Capital gains tax is not progressive like U.S. income taxes. Short-term capital gains are taxed at the investor's top individual income tax bracket. Long-term capital gains are taxed at either 0%, 15%, or 20%, again depending on the investor's personal income tax rate.

This article was written by

Kent Thune profile picture
Kent Thune, CFP®, is a fiduciary investment advisor specializing in tactical asset allocation and portfolio management with a focus on ETFs and sector investing. Mr. Thune has 25 years of wealth management experience and has navigated clients through four bear markets and some of the most challenging economic environments in history. As a writer, Kent's articles have been seen on multiple investing and finance websites, including Seeking Alpha, Kiplinger, MarketWatch, The Motley Fool, Yahoo Finance, and The Balance. Mr. Thune's registered investment advisory firm is headquartered in Hilton Head Island, SC where he serves clients all around the United States. When not writing or advising clients, Kent spends time with his wife and two sons, plays guitar, or works on his philosophy book that he plans to publish later in 2022.

Disclosure: I/we have no stock, option or similar derivative position in any of the companies mentioned, and no plans to initiate any such positions within the next 72 hours. I wrote this article myself, and it expresses my own opinions. I am not receiving compensation for it. I have no business relationship with any company whose stock is mentioned in this article.

Recommended For You

Comments (2)

To ensure this doesn’t happen in the future, please enable Javascript and cookies in your browser.
Is this happening to you frequently? Please report it on our feedback forum.
If you have an ad-blocker enabled you may be blocked from proceeding. Please disable your ad-blocker and refresh.