It's easy to get caught up in choosing investments and forget about the tax consequences of your strategies. After all, picking the right stock or mutual fund is difficult enough without worrying about after-tax returns. The same thing is true when you invest in other types of capital assets, such as your home.

However, if you truly want the best performance, you have to consider the tax you pay on profits from sales of your investments, whether they are securities, real estate or other capital assets. Figuring that tax into your financial management strategy and timing when it will hit are crucial to getting the most out of your investments. Here we look into the capital gains tax and how you can adjust your investment strategies to minimize the tax you pay. 

The Basics

capital gain is simply the difference between the purchase and selling price of an asset. Expressed as an equation, that means selling price – purchase price = capital gain. (If the price of the asset you purchased has decreased, the result would be a capital loss.) And just as tax collectors want a cut of your income (income tax), they also want a cut when you see a gain in any of your investments. This cut is the capital gains tax.

For tax purposes, it is important to understand the difference between realized gains and unrealized gains. A gain is not realized until the security that has appreciated is sold. Say, for example, you buy some stock in a company and your investment grows steadily at 15% for one year. At the end of the year, you decide to sell your shares. Although your investment has increased since the day you bought the shares, you will not realize any gains until you have sold them.

As a general rule, you don't pay any tax until you've realized a gain. After all, you need to receive the cash made from selling at least part of your investment in order to pay any tax.

Which Assets Get Capital Gains Treatment?

As we shall see, the capital gains tax rate is often lower than the rate you'd pay on ordinary income, which can make it a more desirable category for investment income. Be aware, however, that not every asset is eligible for this benefit. 

For capital gains treatment to apply, you first need to be sure you’re dealing with a capital asset. Clearly, stocks, bonds, jewelry, coin collections and your home are capital assets.

But the law does not give capital asset treatment to every capital asset you have, including:

  • your business inventory  
  • depreciable business property

Also excluded from capital gains treatment are certain items (“noncapital assets”) you create or have produced for you:

  • a copyright; a literary, musical or artistic composition; a letter; a memorandum; or similar property (e.g., drafts of speeches, recordings, transcripts, manuscripts, drawings or photographs)
  • a patent, invention, model or design (whether or not patented); also a secret formula or process sold after 2017

Holding Periods: Short Term vs. Long Term

Even if the asset is eligible, how long you have owned it before selling affects how you will be taxed. To use the favorable long-term capital gains rates, capital assets must be held for more than one year. Any gain on assets that are held for one year or less are short-term capital gains, which are taxed at ordinary income rates. The tax system in the United States is set up to benefit the long-term investor. Short-term investments are almost always taxed at a higher rate than long-term investments.

An Example of How It Works

Say you bought 100 shares of XYZ stock at $20 per share and sold them at $50 per share, and say you fall into the income category (see "What You'll Owe," below) in which the government taxes your long-term gains at 15%. The table below summarizes how your gains from XYZ stock are affected.

Bought 100 shares @ $20 $2,000
Sold 100 shares @ $50 $5,000
Capital gain $3,000
Capital gain taxed @ 15% $450
Profit after tax $2,550

Uncle Sam is getting his hands on $450 of your profits. But had you held the stock for less than one year (making a short-term capital gain), your profit would have been taxed at your ordinary income tax rate, which can be as high as 35% for people whose long-term capital gains tax is 15%, not counting any additional state taxes. Note again that you pay the capital gains tax only when you have sold your investment or real estate and have realized a gain. Having a lower tax rate than what you pay on ordinary income is why being eligible for capital gains tax can be so beneficial to taxpayers.

Losing Compounding: When a Capital Gain Is a Loss

Even the lower capital gains tax hit isn’t the only loss investors face when they sell at a profit.  Because of compounding – the phenomenon of reinvested earnings generating more earnings – that $450 capital-gains hit could potentially be worth more if you keep it invested. If you buy and sell stocks every few months, you are undermining the potential worth of your earnings: Instead of letting them compound, you are giving them away to taxes.

Again, this all comes down to the difference between an unrealized and realized gain. To demonstrate this, let's compare the tax consequences to the returns of a long-term investor and a short-term investor, assuming a 20% tax rate. This long-term investor realizes that year over year, they can average a 10% annual return by investing in mutual funds and a couple of blue-chip stocks. The short-term investor is not a day trader, but they like to hold trades for less than one year, confident that by trading their account frequently they can average a gain of 12% annually. Here is their overall after-tax performance after 30 years. 

  Long-Term (10%) Short-Term (12%)
Initial Investment $10,000 $10,000
Capital gain after one year $0 ($1,000 unrealized) $1,200
Tax paid @ 20% 0 $240
After-tax value in one year $11,000 $10,960
After-tax value in 30 Years $139,595 $120,140

Because our short-term trader ended up giving a good chunk of money to taxes, our long-term investor, who allowed all of their investment to continue earning money, made nearly $20,000 more – even though they were earning a lower rate of return. Had both of them been earning the same rate of return, the difference would be even more staggering. In fact, with a 10% rate of return, the short-term investor would have earned only $80,000 after taxes.

Making constant changes in investment holdings – resulting in high payments of capital gains tax and commissions – is called churning. Unscrupulous portfolio managers and brokers have been accused of churning, or excessively trading a client's account to increase commissions, even though it diminishes returns.

Capital Gains Rates

While the tax rates for individuals on ordinary income are 10%, 12%, 22%, 24%, 32%, 35% and 37%, long-term capital gains rates are taxed at different, generally lower rates. The basic capital gains rates are 0%, 15% and 20%. What you're charged now depends on your taxable income. (The breakpoints for these rates are explained later). Historically, as this chart from the Tax Policy Center shows, individual taxes are generally higher than capital-gains taxes.

There are two other types of capital gains taxes you may encounter:

  • Gains on collectibles, such as artworks and stamp collections, and on the portion of gain on the sale of qualified small business stock that isn’t excluded (called Section 1202 stock) are taxed at a 28% rate.
  • Real estate capital gains are taxed under a different standard if you're selling your principal residence. Here's how it works: $250,000 of an individual's capital gains on the sale of a home are excluded from their income for that year ($500,000 for those married filing jointly), as long as the seller has owned and lived in the home for two years or more.

There is one other tax: Due to the net investment income tax, you may be subject to an additional 3.8% tax on your investment income, including your capital gains, if your modified adjusted gross income (not taxable income) is:

  • over $250,000 if married filing jointly or a surviving spouse
  • $200,000 if single or head of household
  • $125,000 if married filing separately

What You'll Owe

Before 2018, the basic long-term capital gains tax rates were determined by your tax bracket. If, for example, your taxable income was such that you were in one of the two lowest brackets, your capital gains had a zero tax rate; none of your gains were taxed. The Tax Cuts and Jobs Act changed the breakpoints for the basic capital gains rates to align with taxable income (not tax brackets). The following is a chart of the breakpoints for 2018 based on your filing status and taxable income: 

Filing Status

0%

15%

20%

Single

Up to $38,600

$38,601 to $425,800

Over $425,800

Head of household

Up to $51,700

$51,701 to $452,400

Over $452,400

Married filing jointly and surviving spouse

Up to $77,200

$77,201 to $479,000

Over $479,000

Married filing separately

Up to $38,600

$38,601 to $239,500

Over $239,500

How to Figure Your Capital Gains Tax

Most individuals figure their tax (or have pros do it for them) using software that automatically makes computations. But if you want to get an idea of what you may pay on a potential or actualized sale, you can use a capital gains calculator to get a rough idea. 

And 5 Ways to Minimize or Avoid Capital Gains Tax

There are a few ways to minimize or avoid capital gains. Here is what to keep in mind:

1. Invest for the long term. 

If you manage to find great companies and hold them for the long term, you will pay the lowest rate of capital gains tax. Of course, this is easier said than done. Many factors can change over a number of years, and there are many valid reasons why you might want to sell earlier than you anticipated.

2. Use tax-advantaged retirement plans. 

There are numerous types of retirement plans available, such as 401(k)s403(b)sRoth IRAs and traditional IRAs. Details vary with each plan but, in general, the prime benefit is that investments can grow without being subject to capital gains tax. In other words, within a retirement plan, you can buy and sell without losing a cut to Uncle Sam. Additionally, most plans do not require participants to pay tax on the funds until they are withdrawn from the plan, although distributions are taxed as ordinary income regardless of the underlying investment. So, not only will your money grow in a tax-free environment, but when you take it out of the plan at retirement you'll likely be in a lower tax bracket.

3. Use capital losses to offset gains. 

If you experience an investment loss, you can take advantage of it by decreasing the tax on your gains on other investments. Say you are equally invested in two stocks and one company's stock rises by 10% while the other company's stock falls by 5%. You can subtract the 5% loss from the 10% gain, thereby reducing the amount on which you pay capital gains. Obviously, in an ideal situation, all your investments would be appreciating, but losses do happen, so it's important to know that you can use them to minimize what you may owe in taxes.

However, capital losses can only be used currently to offset capital gains for the year, plus up to $3,000 of ordinary income; excess losses get carried forward. Also, be sure to wait at least 31 days before buying back the losing position in order to satisfy the IRS wash-sale rule.

If you are going to realize material capital gains of any kind, you must report them to the IRS on a Schedule D form. You should also consider enlisting the help of an accountant or other financial advisor.

4. Watch your holding periods. 

If you are selling a security that was bought about a year ago, be sure to find out the actual trade date of the purchase. Should the sale be eligible for capital gains treatment if you wait to sell for a few days, this may be a wise move as long as the price of the investment being sold is holding at a relatively steady price. This will matter more for large trades than small ones, and also if you are in a higher tax bracket. Remember that a security must be sold after more than a year to the day in order for the sale to qualify for capital gains treatment.

5. Pick your basis. 

Although you will typically use the first in, first out (FIFO) method to calculate cost basis when you acquire shares in the same company or mutual fund at different times, there are four other methods to choose from: last in, first out (LIFO)dollar value LIFOaverage cost (only for mutual fund shares) and specific share identification. The best choice will depend on several factors, such as the basis price of shares or units that were purchased and the amount of gain that will be declared. For complex cases, you may need to consult a tax advisor. Computing cost basis can be a tricky proposition, but finding out when a security was purchased and at what price can be a real nightmare if you have lost the original confirmation statement or other records from that time.

The Bottom Line

Minimizing taxes is an important element of the financial planning process. Although the tax tail should not wag the entire financial dog, it is critical that you take reasonable measures to reduce reportable gains and realize losses against them. The two main ways to reduce the tax you pay are to hold stocks for longer than one year and to allow investments to compound tax free in retirement-savings accounts.