The person who sells an asset for more than they paid for it pays capital gains tax

Capital gains tax is owed by whoever sells property, stock, cryptocurrency, a business, or other assets at a profit. The tax applies to the difference between what you paid for the asset (your basis) and what you sold it for (your sale price). If you buy a house for $300,000 and sell it for $400,000, the $100,000 difference is your capital gain, and that is what gets taxed.

You do not pay capital gains tax on assets you still own, only when you sell them. You also do not pay it if you sell at a loss — in fact, you can use losses to reduce gains from other sales. The tax is owed to the federal government and, in most states, to your state as well.

Key Takeaways

  • Capital gains tax is paid by the person who sells the asset, calculated on the profit (sale price minus what you originally paid).
  • Long-term capital gains — assets held for more than one year — are taxed at lower federal rates (0%, 15%, or 20%) than short-term gains, which use your regular income tax rate.
  • Your primary residence may be exempt from capital gains tax if you meet the ownership and use test: you owned and lived in the home for at least two of the last five years.
  • You report capital gains on your federal tax return (Form 1040) and on your state return if your state has a capital gains tax.
  • Capital losses from one sale can reduce capital gains from other sales in the same year, and unused losses can carry forward to future years.

Long-term versus short-term capital gains rates

The federal tax rate on your capital gain depends on how long you held the asset. If you owned it for more than one year, it is a long-term gain and taxed at a preferential rate: 0%, 15%, or 20%, depending on your total income. If you owned it for one year or less, it is a short-term gain and taxed as ordinary income at your regular tax bracket rate, which can be as high as 37%.

This difference is significant. A person in the 37% tax bracket who sells stock held for eight months owes 37% on the gain. The same person selling stock held for 13 months owes only 20%. The holding period is measured from the date you bought the asset to the date you sold it.

Long-term rates also vary by income level. For 2024, the 0% rate applies to single filers with income below roughly $47,000; the 15% rate applies to income between that threshold and roughly $518,000; and the 20% rate applies above that. These thresholds change each year. Your tax professional or the IRS website can tell you which rate applies to your situation.

The primary residence exemption

If you sell your main home, you may not owe capital gains tax on the profit at all. The Section 121 exclusion allows you to exclude up to $250,000 of gain if you are single, or $500,000 if you are married filing jointly. To may have access to, you must have owned the home and lived in it as your primary residence for at least two of the five years before the sale.

This exemption applies only once every two years. If you sold a home and used the exclusion two years ago, you can use it again now. If you sold one 18 months ago, you cannot use it until the two-year mark passes. The exemption is generous enough that most homeowners owe no capital gains tax on a home sale, even if they made a substantial profit.

Rental properties, vacation homes, and investment real estate do not may have access to for this exemption. If you rent out part of your home, the exemption may be reduced based on the rental portion and the years you rented it.

How capital gains are reported and paid

You report capital gains on Schedule D (Capital Gains and Losses), which attaches to your Form 1040 federal tax return. You list each asset you sold, the date you bought it, the date you sold it, your basis, your sale price, and the gain or loss. The IRS uses the holding period to sort your gains into long-term and short-term categories, then applies the correct tax rates.

If you sold stock, real estate, or other assets through a broker or financial institution, that entity sends you a Form 1099-B or Form 1099-S showing the sale details. The IRS receives a copy too, so your return must match. If you sold a home, your title company or real estate agent typically reports the sale on Form 1099-S.

Capital gains tax is paid when you file your return, usually by April 15 of the following year. If you expect a large gain, you may need to make estimated tax payments during the year to avoid penalties. Your tax professional can advise whether your situation requires this.

State capital gains taxes

Most states do not have a separate capital gains tax — they tax capital gains as part of ordinary income using their regular income tax rate. However, a growing number of states have introduced capital gains taxes on certain types of gains, usually on the sale of stocks, bonds, and other financial assets. Washington, Illinois, and California have capital gains taxes; others have proposed them.

State capital gains taxes vary widely in scope and rate. Some explore only to gains above a certain threshold (for example, gains over $250,000 in a year). Some exclude certain assets like real estate or retirement accounts. Rates range from roughly 5% to 13.3%, depending on the state. If you live in a state with a capital gains tax and you sell an asset, you will owe both federal and state tax on the gain.

If you move to a different state after selling an asset, the state where you lived when you sold it is the one that taxes the gain, not your new state. This matters if you are relocating and planning a large sale.

Capital losses and offsetting gains

If you sell an asset at a loss, you can use that loss to reduce capital gains from other sales in the same year. If you sold stock for a $5,000 loss and real estate for a $12,000 gain, your net capital gain is $7,000, and you owe tax only on that amount. This is called loss harvesting and is a common strategy for managing tax liability.

If your losses exceed your gains in a year, you can deduct up to $3,000 of the net loss against your ordinary income. Any remaining loss carries forward to future years, where you can use it to offset future gains or ordinary income. This carryforward has no expiration — you can use it whenever you have gains or income to offset.

To claim a loss, you must report it on Schedule D just as you would a gain. The IRS will not automatically know you had a loss unless you tell them.

Who does not pay capital gains tax

If you inherit an asset, your basis is "stepped up" to its fair market value on the date of the person's death. If the asset was worth $100,000 when inherited and you sell it for $105,000 a year later, you owe tax only on the $5,000 gain, not on the appreciation that happened before you inherited it. This is a major tax advantage of inherited assets.

If you give an asset to someone else during your lifetime, the recipient takes on your original basis. If you bought stock for $10,000 and give it to your child when it is worth $50,000, your child's basis is $10,000. If they sell it for $60,000, they owe tax on $50,000 of gain. Gifts do not get a step-up in basis the way inheritances do.

Frequently Asked Questions

Do I owe capital gains tax if I sell my home at a loss?

No. Capital losses on personal residences cannot be deducted. If you sell your primary home for less than you paid for it, you straightforward report no gain and owe no tax. The loss cannot be used to offset other gains or income.

What if I sold an asset but have not received the money yet?

You owe capital gains tax in the year you sold the asset, not when you receive payment. If you sold property in 2024 but the buyer is paying you in installments through 2025, you still report the gain on your 2024 return. Installment sales have special rules — ask a tax professional if this applies to you.

Can I avoid capital gains tax by donating the asset to charity instead of selling it?

Yes. If you donate appreciated stock or property to a may have access to charity, you avoid the capital gains tax entirely and also receive a charitable deduction for the asset's full fair market value. This is often more valuable than selling and donating the proceeds.

Do I owe capital gains tax on cryptocurrency or digital assets?

Yes. The IRS treats cryptocurrency and digital assets like any other property. When you sell, trade, or exchange them, you owe capital gains tax on the profit. The holding period determines whether it is taxed as long-term or short-term gain.

What if I made a capital gain in a year I had no income?

You still owe capital gains tax on the gain. Capital gains are taxed separately from ordinary income and use their own tax brackets. Even if you had no wages or salary, a capital gain is taxable income and must be reported.