What federal capital gains tax is and who pays it
Federal capital gains tax is a tax on the profit you make when you sell an investment or asset for more than you paid for it. The difference between what you paid and what you sold it for is your gain, and that gain is taxable income at the federal level.
You pay this tax only when you actually sell the asset and realize the profit. If you own stock that goes up in value but you never sell it, you owe no tax on that gain yet. The moment you sell it, the IRS considers that a taxable event.
Not everyone pays capital gains tax every year. You only owe it if you sell investments, real estate, or other assets at a profit. If you sell something for less than you paid, you have a loss, which can reduce other gains or, in some cases, reduce your ordinary income.
Key Takeaways
- Capital gains tax applies to the profit from selling investments, real estate, or other assets, and is calculated as the selling price minus what you originally paid.
- Long-term capital gains (assets held over one year) are taxed at lower federal rates than short-term gains, which are taxed as ordinary income.
- The federal long-term capital gains tax rates are 0%, 15%, or 20%, depending on your total income for the year.
- You report capital gains on your federal tax return using Schedule D, and the IRS matches this against records from your broker or the person who bought your asset.
Long-term versus short-term capital gains
The IRS treats capital gains differently depending on how long you held the asset. If you held it for more than one year before selling, it is a long-term capital gain. If you held it for one year or less, it is a short-term capital gain.
Short-term capital gains are taxed as ordinary income at your regular federal income tax rate, which can be as high as 37% depending on your income bracket. Long-term capital gains receive preferential treatment and are taxed at lower federal rates: 0%, 15%, or 20%.
This difference matters significantly. Suppose you bought stock for $5,000 and sold it eight months later for $7,000. Your $2,000 gain would be taxed as short-term income at your regular rate. If you had held that same stock for 14 months and sold it for $7,000, the same $2,000 gain would be taxed at the lower long-term rate, which could save you hundreds of dollars in federal tax.
How the 0%, 15%, and 20% rates work
The federal long-term capital gains rate you pay depends on your total taxable income for the year, not on the size of the gain itself. The IRS sets income thresholds that change each year, and your filing status matters—single filers have different thresholds than married filers or heads of household.
If your total taxable income falls below a certain threshold, your long-term capital gains are taxed at 0%. If it falls in the middle range, you pay 15%. If it exceeds the highest threshold, you pay 20%. These thresholds are adjusted annually for inflation, so the exact dollar amounts change from year to year.
For example, if you are a single filer in 2024 and your taxable income (including your capital gains) is below roughly $47,000, your long-term gains are taxed at 0%. Between roughly $47,000 and $518,000, they are taxed at 15%. Above that, they are taxed at 20%. Married filers filing jointly have higher thresholds. These numbers shift each tax year, so you should check the current year's thresholds on the IRS website or with a tax professional.
How to report capital gains on your tax return
You report capital gains to the IRS using Schedule D, which is a form you attach to your federal tax return (Form 1040). On Schedule D, you list each asset you sold, the date you bought it, the date you sold it, what you paid for it, what you sold it for, and the resulting gain or loss.
Your broker or the person who bought your asset from you is required to send you (and the IRS) a form called Form 1099-B or Form 1099-S, depending on what you sold. The IRS receives a copy of this form too, so they know what you sold and for how much. If the numbers on your Schedule D do not match what the IRS received, you may be contacted for clarification.
If you sold real estate, the buyer's closing agent typically sends Form 1099-S to you and the IRS. If you sold stocks, mutual funds, or other securities, your brokerage sends Form 1099-B. Keep records of your purchase price and date—receipts, statements, or confirmations—because you will need them to calculate your gain accurately.
State and local capital gains taxes
Federal capital gains tax is separate from state and local taxes. Some states tax capital gains as ordinary income, some tax them at a lower rate, and a few do not tax them at all. Your state's rules depend on where you live and, sometimes, where the asset was located.
A handful of states—including Washington, Tennessee, and Florida—have no state income tax, so residents pay no state capital gains tax. Others, like California and New York, tax capital gains at the same rate as ordinary income, which can be quite high. Still others tax capital gains at a preferential rate or only on certain types of assets.
When you file your federal return, you will also file a state return (if your state requires one), and you will report your capital gains there as well. The state rules for what counts as a gain, how long you must hold an asset, and what rates explore are often different from federal rules, so do not assume they are the same.
When you might owe capital gains tax without selling
In most cases, you owe capital gains tax only when you sell. However, there are exceptions. If you inherit an asset, you generally receive a stepped-up basis, which means the IRS treats the asset's value on the date of death as your new starting price. If you then sell it shortly after, you owe tax only on gains that occurred after you inherited it, not on gains that occurred while the previous owner held it.
If you receive stock or other assets as compensation for work—such as restricted stock units from your employer—you may owe tax when the restriction lifts or when you receive the shares, even if you have not sold them yet. Your employer will report this on your W-2 or a separate form, and it is treated as ordinary income, not a capital gain.
If you own a mutual fund or exchange-traded fund (ETF) and the fund itself sells securities at a profit, the fund may distribute those gains to you. You owe tax on those distributions even though you did not sell the fund itself. The fund will send you a form showing the amount of the distribution.
Losses and how they reduce your tax bill
If you sell an asset for less than you paid for it, you have a capital loss. You can use capital losses to offset capital gains. If you have $5,000 in gains and $3,000 in losses, you report a net gain of $2,000 and pay tax only on that amount.
If your losses exceed your gains in a given year, you can deduct up to $3,000 of the excess loss against your ordinary income (such as wages or salary). If your losses are larger than $3,000, you can carry the remaining loss forward to future years and use it to offset gains or income in those years.
This is why some investors deliberately sell losing positions before the end of the year—a practice called tax-loss harvesting. By realizing the loss, they can reduce their tax bill. However, there is a rule called the wash-sale rule that prevents you from when ready buying back the same or a substantially identical security within 30 days before or after the sale. If you do, the IRS will not allow the loss.
Frequently Asked Questions
Do I owe capital gains tax if I sell my home?
Most homeowners do not. If you are single and your gain is under $250,000, or married filing jointly and your gain is under $500,000, you can exclude the gain from your income entirely. You must have owned and lived in the home as your primary residence for at least two of the five years before the sale. Gains above those thresholds are taxable.
What is the difference between capital gains and dividends?
Capital gains are profits from selling an asset. Dividends are payments a company makes to shareholders from its earnings, usually quarterly. may have access to dividends (from U.S. companies or certain foreign companies) are taxed at the same long-term capital gains rates. Nonqualified dividends are taxed as ordinary income.
Can I deduct investment losses on my taxes?
Yes. You can use capital losses to offset capital gains dollar-for-dollar. If losses exceed gains, you can deduct up to $3,000 against ordinary income in that year. Losses above $3,000 carry forward to future years with no time limit.
Do I have to report capital gains if I did not receive a 1099 form?
Yes. You are required to report all capital gains, whether or not you receive a 1099 form. The IRS may not catch an unreported gain when ready, but if the buyer or broker reported it, the IRS will eventually match the records and contact you. It is safer and simpler to report it yourself.
What happens if I hold an investment for exactly one year?
The holding period is measured from the purchase date to the sale date. If you bought on January 15, 2023, and sold on January 15, 2024, you held it for exactly one year, which qualifies as long-term. If you sold on January 14, 2024, it would be short-term. The IRS counts the purchase date as day one.