Sell a stock for more than you paid, and you’ve made a capital gain. It sounds simple, but a lot of people don’t realize the IRS wants a cut of that profit until they’re staring at a tax bill they weren’t expecting. That surprise is avoidable with a little upfront knowledge.

This article breaks down exactly what a capital gain is, how it gets taxed, which assets trigger it, and how to legally keep more of your money. Whether you’re investing in stocks, selling a home, or just trying to make sense of your 1099, you’ll walk away with a clear picture of how capital gains work.
What Is a Capital Gain?
A capital gain is the profit you make when you sell a capital asset for more than you originally paid for it. The formula is straightforward: sale price minus your cost basis equals your capital gain.
For example, if you bought shares of stock for $5,000 and later sold them for $8,000, you have a $3,000 capital gain. That $3,000 is what the IRS taxes, not the full $8,000 you received.
The term “cost basis” refers to what you originally paid for the asset, including any fees or commissions. It’s worth tracking carefully because a higher cost basis means a smaller taxable gain.
What Counts as a Capital Asset?
Capital assets cover a wide range of things people buy, hold, and eventually sell. Here are the most common examples:
- Stocks: Individual shares, ETFs, and mutual funds held in taxable brokerage accounts.
- Real estate: Investment properties, vacation homes, and in some cases your primary residence.
- Cryptocurrency: The IRS treats crypto as property, so every sale or trade is a taxable event.
- Collectibles: Art, coins, antiques, and other tangible items held as investments.
- Bonds: Corporate and municipal bonds sold before maturity at a profit.
- Business assets: Equipment, patents, or other property sold as part of a business.
What Is a Capital Loss?
A capital loss is the opposite of a capital gain. It occurs when you sell an asset for less than you paid. While losing money is never the goal, capital losses have real tax value because they can offset your capital gains and reduce what you owe. This strategy is called tax-loss harvesting, and it’s a legitimate way to lower your tax bill at the end of the year.
Short-Term vs. Long-Term Capital Gains
Not all capital gains are taxed the same way. The IRS draws a hard line based on how long you held the asset before selling it, and the difference in tax treatment can be significant.
Short-term capital gains apply to assets held for one year or less. The IRS taxes these at your ordinary income tax rate, which can be as high as 37% depending on your income bracket. Long-term capital gains apply to assets held for more than one year, and they’re taxed at lower preferential rates of 0%, 15%, or 20%.
That one extra day of holding can make a real difference. Consider a $20,000 gain. As a short-term gain in the 32% bracket, you’d owe $6,400 in federal taxes. As a long-term gain taxed at 15%, you’d owe $3,000. Same profit, very different tax bill.
Why the Holding Period Matters So Much
The IRS rewards patience. The long-term capital gains rates exist as a policy incentive to encourage long-term investing rather than rapid trading. For most people, simply holding an investment for more than a year before selling is the single easiest way to reduce capital gains taxes.
It’s worth keeping a close eye on the exact purchase date of any asset you’re considering selling. If you’re a few weeks away from crossing the one-year threshold, waiting it out can save you a meaningful amount in taxes.
Capital Gains Tax Rates for 2025 and 2026
Long-term capital gains tax rates remain at 0%, 15%, and 20%, but the income thresholds shift each year with inflation adjustments. Here are the brackets for 2026 (for returns filed in early 2027) for single filers:
- 0%: Applies to taxable income up to $49,450.
- 15%: Applies to taxable income between $49,451 and $553,400.
- 20%: Applies to taxable income above $553,400.
For married couples filing jointly in 2026, the 0% rate applies to taxable income up to $98,900. The 15% rate applies up to $623,050, and the 20% rate kicks in above that.
Short-term capital gains don’t have their own brackets. They’re added to your ordinary income and taxed at whatever federal rate applies to your total income for the year, which ranges from 10% to 37%.
One additional tax to be aware of is the Net Investment Income Tax (NIIT). High earners, specifically single filers with modified adjusted gross income above $200,000 or joint filers above $250,000, pay an extra 3.8% on their net investment income, which includes capital gains. These NIIT thresholds are not adjusted for inflation, so they remain the same from year to year.
Which Assets Trigger Capital Gains Taxes?
Any time you sell a capital asset at a profit in a taxable account, you’ve likely triggered a capital gain. The most common situations include selling stocks or ETFs in a brokerage account, selling an investment property, or exchanging one cryptocurrency for another.
Mutual funds add a layer of complexity. Even if you never sell your mutual fund shares, the fund manager may sell securities inside the fund and distribute the gains to all shareholders. You’ll owe tax on those distributed gains even if you reinvested them automatically.
Collectibles get their own special treatment under the tax code. Long-term gains on collectibles like art, coins, and antiques are taxed at a maximum rate of 28%, which is higher than the standard 20% top rate for other long-term assets.
When You Don’t Owe Capital Gains Tax
Several situations allow you to avoid or defer capital gains taxes entirely. These aren’t loopholes; they’re rules built directly into the tax code.
- Tax-advantaged accounts: Gains inside a traditional 401(k), IRA, or Roth IRA are either tax-deferred or tax-free. You won’t owe capital gains tax on trades made within these accounts.
- Primary home exclusion: If you’ve lived in your home for at least two of the last five years, you can exclude up to $250,000 of gain from taxes as a single filer, or up to $500,000 if you’re married filing jointly.
- Inherited assets: Assets passed down through an estate receive a “stepped-up” cost basis. The basis is reset to the asset’s fair market value on the date of death, which often eliminates a significant taxable gain.
- Gifts to charity: When you donate appreciated assets directly to a qualified charity instead of selling them first, you avoid capital gains taxes entirely and may also receive a charitable deduction.
How Capital Gains Are Reported on Your Tax Return
Capital gains are reported on your federal tax return using two forms: Form 8949 and Schedule D. Form 8949 is where you list each individual sale, including the asset, purchase date, sale date, cost basis, and proceeds. Schedule D summarizes those totals and calculates your overall gain or loss for the year.
Your brokerage will send you a Form 1099-B at the start of each tax year. This form lists every sale made in your taxable accounts and often includes your cost basis. Reviewing this form carefully is important because errors in reported cost basis are common, especially for older assets or shares purchased through dividend reinvestment programs.
Capital gains taxes aren’t withheld automatically the way payroll taxes are. You pay them when you file your return in April, which means a large gain late in the year could result in an underpayment penalty if you didn’t make estimated tax payments throughout the year. If you sell something for a significant profit, it’s worth checking whether you need to make a quarterly estimated payment to the IRS.
5 Legal Ways to Reduce Your Capital Gains Tax
Minimizing capital gains taxes is one of the most straightforward ways to improve your overall investment returns. The strategies below are all legitimate and widely used.
The most powerful move is simply holding assets for more than one year before selling. Beyond that, tax-loss harvesting, account selection, and charitable giving can all make a real dent in what you owe.
- Hold for the long term: Selling after one year qualifies your gain for the lower long-term rates of 0%, 15%, or 20% instead of your ordinary income rate.
- Harvest tax losses: Sell underperforming investments to generate losses that offset gains elsewhere in your portfolio. You can deduct up to $3,000 of net losses against ordinary income per year, with the remainder carried forward.
- Invest inside tax-advantaged accounts: Max out your 401(k), IRA, and HSA contributions so that gains accumulate either tax-deferred or tax-free.
- Use the home sale exclusion: If you’re selling your primary residence, make sure you meet the two-out-of-five-year ownership and use tests to qualify for the $250,000 or $500,000 exclusion.
- Donate appreciated assets: Give stocks or other appreciated assets directly to a charity. You avoid capital gains tax and may deduct the full fair market value of the donation.
Advanced Strategies: 1031 Exchanges and Opportunity Zones
Real estate investors have two additional tools available. A 1031 exchange allows you to defer capital gains taxes on an investment property sale by rolling the proceeds into a like-kind property within a set timeframe.
Opportunity Zone investments allow you to defer and potentially reduce capital gains by investing in designated low-income communities. Both strategies come with strict rules and deadlines, so working with a tax advisor is important before moving forward with either one.
Capital Gains vs. Ordinary Income: What’s the Difference?
Ordinary income includes your wages, salary, freelance income, rental income, and interest. It’s taxed at rates ranging from 10% to 37% based on your total income. Short-term capital gains are folded into this category and taxed the same way.
Long-term capital gains are treated as a separate category with their own lower tax rates. The tax code does this intentionally to encourage people to invest for the long term rather than trade constantly. From a planning perspective, this distinction means that how long you hold an asset can matter just as much as how much you earn from selling it.
One thing worth knowing: capital gains don’t affect your ordinary income tax bracket directly. They’re calculated separately on Schedule D. However, large capital gains can increase your adjusted gross income, which may affect your eligibility for certain deductions, credits, or the NIIT threshold.
Bottom Line
Capital gains are simply the profit you make when you sell an asset for more than you paid. How they’re taxed depends on two key factors: how long you held the asset and what type of account it’s in. Get those two things right, and you can significantly reduce your tax bill without doing anything complicated.
The most actionable takeaways are to hold investments for at least one year, prioritize tax-advantaged accounts for your most active trading, and track your cost basis carefully so you’re not overpaying taxes on gains that aren’t as large as they look on paper. If you’re expecting a large gain in a given year, talking to a tax professional before you sell is worth the time.