Capital Gains Tax Examples: Crypto, Stock, Real Estate, and Collectibles

Capital gains tax examples make the rules concrete: the tax applies to your profit, not the sale price, and the amount you owe turns on how long you held the asset, your total taxable income, and what kind of asset you sold. The scenarios below walk through the math for stocks, crypto, a home sale, a rental property, and a mixed year of trades using 2026 brackets.

Short-Term Gain on Cryptocurrency

Assets held for one year or less produce short-term capital gains, and the IRS taxes them at the same rates as wages.1Internal Revenue Service. Topic No. 409, Capital Gains and Losses

You buy cryptocurrency for $10,000 in January and sell it in June for $15,000. Your gain is $5,000. Because you held it less than a year, the $5,000 stacks on top of your other income. If your wages already put you in the 24% bracket (for a single filer, roughly $105,700 to $201,775 of taxable income in 2026), the federal tax on that $5,000 gain is $1,200.

Someone in the top 37% bracket would owe $1,850 on that same $5,000 gain. The rate tracks your income level, not the size of the profit.

Long-Term Gain on Stock

Hold an investment for more than one year and the profit qualifies for preferential long-term rates of 0%, 15%, or 20%.1Internal Revenue Service. Topic No. 409, Capital Gains and Losses For 2026, the thresholds are:2Tax Foundation. 2026 Tax Brackets and Federal Income Tax Rates

  • 0% rate: taxable income up to $49,450 (single), $98,900 (married filing jointly), or $66,200 (head of household).
  • 15% rate: taxable income from $49,451 to $545,500 (single), $98,901 to $613,700 (married filing jointly), or $66,201 to $579,600 (head of household).
  • 20% rate: taxable income above $545,500 (single), $613,700 (married filing jointly), or $579,600 (head of household).

You bought shares of a mutual fund three years ago for $50,000 and sell them today for $100,000. Your long-term gain is $50,000. If your total taxable income lands in the 15% bracket, you owe $7,500 in federal capital gains tax.

Now change one variable. If you had sold those same shares after six months, the $50,000 gain would be taxed as ordinary income. A single filer in the 24% bracket would owe $12,000 instead of $7,500. The $4,500 difference is what waiting past the one-year mark buys you.

Selling a Primary Residence

The tax code carves out its most generous exclusion for the sale of your main home. You can exclude up to $250,000 of gain from the sale of a principal residence, or up to $500,000 on a joint return.3Office of the Law Revision Counsel. 26 USC 121 – Exclusion of Gain From Sale of Principal Residence To qualify, you must have owned the home and used it as your principal residence for at least two of the five years before the sale, and you can’t have used the exclusion on another sale within the previous two years.4Internal Revenue Service. Topic No. 701, Sale of Your Home The two years don’t need to be consecutive.

A married couple bought their home for $300,000, lived there eight years, and sold for $700,000. Their gain is $400,000. That falls below the $500,000 joint exclusion, so federal capital gains tax is zero.

Change the facts: same numbers, but the seller is single. The first $250,000 of the $400,000 gain is excluded, leaving $150,000 taxable at the long-term rate. At 15%, that is $22,500.

Rental Property With Depreciation Recapture

If you claimed depreciation on a rental, the portion of your gain attributable to that depreciation is taxed at a maximum rate of 25%, not the standard long-term rate.5Internal Revenue Service. Property (Basis, Sale of Home, Etc.) 5 This is called unrecaptured Section 1250 gain.

You bought a rental property for $300,000 and claimed $50,000 in depreciation over the years, dropping your adjusted basis to $250,000. You sell for $400,000. Total gain: $150,000. The first $50,000, which matches the depreciation you took, is taxed at 25%, costing $12,500. The remaining $100,000 goes at your regular long-term rate. At 15%, that is $15,000. Total federal tax: $27,500.

Many rental owners budget only for the 15% rate and are short by the recapture amount at filing time.

Collectibles

Long-term gains on art, antiques, rare coins, stamps, and precious metals are taxed at a maximum rate of 28%.

Sell a painting after two years for a $20,000 profit and the federal tax at 28% is $5,600. The same $20,000 gain on corporate stock at 15% would run $3,000. The $2,600 gap comes purely from the asset type, and it catches first-time sellers of inherited jewelry or coin collections off guard.

Netting Gains and Losses in a Single Year

You don’t pay tax on each winning trade in isolation. At year-end, you combine all your capital gains and losses.6Office of the Law Revision Counsel. 26 US Code 1222 – Other Terms Relating to Capital Gains and Losses Short-term gains and losses net first, long-term gains and losses net, then the two results combine.

During 2026, you sell Stock A for a $5,000 long-term gain and Stock B for a $2,000 long-term loss. Your net long-term gain is $3,000, and that is what gets taxed.

When total losses exceed total gains, you can deduct up to $3,000 of the net loss against wages or other ordinary income ($1,500 if married filing separately).7Office of the Law Revision Counsel. 26 USC 1211 – Limitation on Capital Losses Losses beyond that carry forward. So $15,000 in net losses this year yields a $3,000 deduction in 2026 and $12,000 carried into 2027 and later years.1Internal Revenue Service. Topic No. 409, Capital Gains and Losses

One boundary matters if you plan to harvest losses. Sell a security at a loss and buy the same or a substantially identical one within 30 days before or after the sale, and the IRS disallows the loss for the current year.8Office of the Law Revision Counsel. 26 USC 1091 – Loss From Wash Sales of Stock or Securities The disallowed amount adds to the basis of the replacement shares, so it isn’t gone forever, but you can’t use it against this year’s gains. Wait at least 31 days to repurchase.

The 3.8% Surtax for Higher Earners

An additional 3.8% Net Investment Income Tax (NIIT) applies once your modified adjusted gross income clears these thresholds:9Office of the Law Revision Counsel. 26 USC 1411 – Imposition of Tax

  • $200,000 for single filers
  • $250,000 for married couples filing jointly
  • $125,000 for married individuals filing separately

The 3.8% hits the smaller of your net investment income or the amount your income exceeds the threshold. On a $100,000 long-term gain that pushes you fully past the line, the surtax adds $3,800. That is why the effective top federal rate on long-term gains is 23.8%, not 20%.

A Mixed Year Tying It Together

A single filer earns $120,000 in wages during 2026 and sells two investments. The first is stock held 18 months with a $30,000 long-term gain. The second is cryptocurrency held four months with a $10,000 short-term gain.

The $10,000 short-term crypto gain is ordinary income. Added to $120,000 in wages, it sits in the 24% bracket and produces $2,400 in federal tax. The $30,000 long-term stock gain is taxed at 15% because total taxable income stays inside the 15% long-term threshold for single filers, producing $4,500. Modified adjusted gross income of $160,000 is under the $200,000 NIIT threshold, so no surtax.9Office of the Law Revision Counsel. 26 USC 1411 – Imposition of Tax Total federal capital gains tax: $6,900.

Hold that crypto for 13 months instead of four and the $10,000 also qualifies for the 15% rate, cutting its tax from $2,400 to $1,500. Same trades, $900 less to the IRS.

State Tax Sits on Top

Every figure above is federal only. Most states also tax capital gains, usually as ordinary income, at rates ranging from 0% in states with no income tax to over 13% in the highest-tax states. If your state taxes investment income, add its rate to each of the examples to see the full bill.