You pay capital gains tax on the profit from selling any asset that increases in value, including stocks, real estate, mutual funds, and cryptocurrency. The tax applies only to the gain-the difference between your purchase price and the sale price-not the total sale amount.
Capital gains are categorized as either short-term or long-term based on how long you held the asset. If you sell an asset within one year of buying it, the gain is short-term and taxed at your ordinary income tax rate. If you hold it longer than 12 months, the gain is long-term and taxed at lower, preferential rates set by federal law.
The IRS defines capital gains as realized when you dispose of an asset through sale, exchange, or liquidation. This includes inherited property sold after death, gifted assets, and even assets surrendered in a divorce settlement. You don't owe capital gains tax simply for holding an appreciated asset-you only pay when you sell it.
Any time you sell an asset for more than your original cost basis, you realize a capital gain. The cost basis includes the purchase price plus any associated fees, commissions, or improvements. For example, if you bought 100 shares of Apple stock at $150 per share and paid $10 in commission, your cost basis is $15,010.
If you later sell those shares at $200 per share ($20,000 total), your gain is $4,990 ($20,000 − $15,010). That $4,990 is subject to capital gains tax. The IRS requires you to report this on Form 8949 and Schedule D of your tax return.
Common assets that trigger capital gains include:
Capital gains tax rates depend on your income level and holding period. As of 2024, long-term capital gains rates are 0%, 15%, or 20% depending on your taxable income. Short-term gains are taxed at your regular federal income tax rate, which can go up to 37%.
For example, if you earned $120,000 in 2024 and sold a stock held for 11 months, the profit is taxed as short-term income. At your marginal rate of 24%, a $10,000 gain results in $2,400 in capital gains tax. But if you held the same stock for 18 months, the gain qualifies for long-term rates-15%-so the tax drops to $1,500.
| Holding Period | Tax Rate (2024) | Example Gain | Tax Due (at 15%) |
|---|---|---|---|
| Less than 12 months | Up to 37% | $10,000 | $3,700 |
| More than 12 months | 0%, 15%, or 20% | $10,000 | $1,500 |
Non-cash transactions also trigger capital gains. Selling a home you lived in for at least two years may allow you to exclude up to $250,000 ($500,000 for married couples) of gain under IRC Section 121. But if you sell a vacation home or rental property, the full gain is taxable.
Many people assume they owe capital gains tax on dividends or interest income. That's incorrect. Dividends are taxed separately as ordinary income unless they qualify as qualified dividends-then they're taxed at long-term capital gains rates. Interest income is always taxed as ordinary income.
Another misconception: capital gains tax applies only to stocks. In reality, it applies to nearly all appreciating assets. A classic example is a vintage car purchased for $20,000 and sold for $50,000. The $30,000 profit is taxable as capital gains-even though it's not a financial instrument.
A lesser-known rule: if you sell an asset at a loss, you can use that loss to offset gains. Up to $3,000 of net capital losses can be deducted against ordinary income annually. Any excess loss carries forward to future years. This is known as capital loss harvesting.
In January 2022, you bought 500 shares of Tesla at $100 per share, totaling $50,000. You paid $50 in commission. Your cost basis is $50,050.
In June 2024, you sell all 500 shares at $250 per share-$125,000 total. Your gain is $74,950 ($125,000 − $50,050).
Since you held the shares for over 24 months, this is a long-term capital gain. Assuming your taxable income places you in the 15% bracket, your capital gains tax is $11,242.50.
This example shows why tracking cost basis matters. Without recording the commission, your gain would have been overstated by $50, leading to higher tax liability.
The IRS allows certain exclusions. For instance, selling your primary residence under IRC Section 121 lets you exclude up to $250,000 ($500,000 for joint filers) of gain if you've lived in the home for at least two of the past five years. This exemption doesn't apply to secondary homes or investment properties.
Starting in 2026, new proposals may limit the capital gains exemption for high earners. Under current draft legislation, individuals earning over $400,000 annually could see their exclusion reduced or eliminated. These changes are still under review and not yet law.
One key fact often missed: capital gains tax is not withheld automatically. Brokers don't deduct it at sale. You must report it on your annual tax return. If you don't have enough tax withheld from other sources, you may owe additional payments by April 15.
I once advised a client who sold a small business for $1.2 million after owning it for 14 years. He assumed he'd owe little tax because it was long-term. But his income pushed him into the 20% capital gains bracket, and state taxes added another 5%. The total tax bill exceeded $270,000. He hadn't planned for the combined impact of federal and state rates.