You pay federal tax on stock gains for the tax year in which you sell the shares, and the bill is due by April 15 of the following year. The rate depends on how long you owned the stock: sell within one year and the profit is taxed at your ordinary income rates, up to 37%; hold for more than a year and it qualifies for long-term capital gains rates of 0%, 15%, or 20%. If a sale produces a large enough gain that your total tax bill will exceed what your paycheck withholding covers, you may need to send an estimated payment during the quarter you sold, rather than waiting until April.
Selling Is What Triggers the Tax
A stock that doubles in your brokerage account creates no tax bill on its own. Federal tax law only applies once you have a realization event, which usually means selling the shares for cash or exchanging them for something else of value. The gain is the difference between what you received and your cost basis, generally what you originally paid plus any commissions or fees.1Office of the Law Revision Counsel. 26 US Code 1001 – Determination of Amount of and Recognition of Gain or Loss Until you actually sell, the profit is a number on a screen and the IRS has no claim to any of it.
The One-Year Line That Sets Your Rate
The single biggest factor in what rate applies is how long you held the shares before selling. Federal law draws a bright line at one year. Held for one year or less, the gain is short-term and taxed at ordinary income rates, the same brackets that apply to your salary. Held for more than one year, the gain is long-term and qualifies for the lower capital gains rates.2Office of the Law Revision Counsel. 26 US Code 1222 – Other Terms Relating to Capital Gains and Losses
Your holding period starts the day after you buy and ends on the day you sell. Stock purchased on March 1, 2025 becomes long-term on March 2, 2026. Miss that date by a day and the entire gain is taxed at the higher short-term rate. For a sizable position, this is one of the most consequential dates on the calendar.
Federal Tax Rates on Stock Gains for 2026
Short-Term Rates
Short-term gains stack on top of your other income and are taxed at the graduated ordinary rates. For 2026, the brackets run from 10% on the lowest income up to 37% on income above $640,600 for single filers or $768,700 for married couples filing jointly. The 22% bracket kicks in at $50,401 single or $100,801 joint; 24% at $105,701 single or $211,401 joint; 32% at $201,776 single or $403,551 joint; and 35% at $256,226 single or $512,451 joint.3Internal Revenue Service. IRS Releases Tax Inflation Adjustments for Tax Year 2026, Including Amendments From the One, Big, Beautiful Bill A large short-term gain can easily push you into a higher bracket for the year.
Long-Term Rates
Long-term gains are taxed at one of three rates based on your total taxable income. For single filers in 2026, the 0% rate applies to taxable income up to $49,450, the 15% rate covers $49,451 to $545,500, and the 20% rate applies above $545,500. For married couples filing jointly, the 0% rate runs to $98,900, the 15% rate covers $98,901 to $613,700, and the 20% rate applies above $613,700.4Internal Revenue Service. Rev Proc 2025-32 The gap between rates is dramatic. A single filer sitting in the 24% ordinary bracket who holds one extra day cuts the rate on that gain to 15%.
The 3.8% Net Investment Income Tax
Higher earners face an additional 3.8% surtax on investment income, capital gains included. It applies to the lesser of your net investment income or the amount by which your modified adjusted gross income exceeds $200,000 single or $250,000 joint. These thresholds are not adjusted for inflation, so they catch more taxpayers each year.5Internal Revenue Service. Topic No 559, Net Investment Income Tax Stacked with the 20% long-term rate, the top effective federal rate on capital gains reaches 23.8%.
When the Payment Is Actually Due
The April 15 Deadline
For most individual investors, the deadline to file your return and pay any capital gains tax owed is April 15 of the year after the sale.6Internal Revenue Service. Individual Tax Filing Sell at a gain in 2025 and the tax is due April 15, 2026. You can request an extension to file until October 15, but that does not extend the time to pay. Any balance remaining after April accrues interest and late-payment penalties.7Internal Revenue Service. IRS Reminds Taxpayers an Extension to File Is Not an Extension to Pay Taxes
When You Need to Pay Quarterly Instead
The IRS runs on a pay-as-you-go system. If you expect to owe $1,000 or more for the year after withholding and credits, you are generally required to make estimated payments during the year rather than waiting for April.8Internal Revenue Service. Estimated Taxes A single large stock sale can easily cross that threshold on its own. The four deadlines each year:
- April 15, for income received January through March
- June 15, for income received April through May
- September 15, for income received June through August
- January 15 of the following year, for income received September through December
Use Form 1040-ES to calculate and submit these payments. You can pay through the Electronic Federal Tax Payment System, schedule an electronic funds withdrawal when you e-file, or mail a check with a payment voucher.9Internal Revenue Service. Payments
Safe Harbors That Prevent a Penalty
You avoid the underpayment penalty entirely if your total payments (withholding plus estimated) hit one of two marks: at least 90% of what you actually owe for the current year, or at least 100% of the tax shown on last year’s return. If your prior-year adjusted gross income exceeded $150,000 ($75,000 if married filing separately), the prior-year safe harbor rises to 110%.10Internal Revenue Service. 2026 Form 1040-ES, Estimated Tax for Individuals If you fall short, the IRS charges interest on the underpayment. The rate changes quarterly and, as of the most recent announcement, stands at 7% per year, compounded daily.11Internal Revenue Service. Interest Rates Remain the Same for the Fourth Quarter of 2025 For investors who realize a large gain from one sale, the simplest move is often to make a single estimated payment in the quarter the sale happened.
Losses That Reduce What You Owe
Selling a stock at a loss offsets your gains dollar for dollar. The IRS requires you to net short-term gains against short-term losses first, then long-term against long-term. If you still have a net loss after combining both categories, you can deduct up to $3,000 per year ($1,500 if married filing separately) against ordinary income like wages.12Office of the Law Revision Counsel. 26 US Code 1211 – Limitation on Capital Losses Any excess carries forward indefinitely, so a bad year can reduce your tax bills for years to come.13Internal Revenue Service. Topic No 409, Capital Gains and Losses
Watch for the wash sale rule. If you sell a stock at a loss and buy the same stock (or something substantially identical) within 30 days before or after the sale, the IRS disallows the loss. The disallowed amount is added to the cost basis of the replacement shares, so it is not gone forever, but it will not reduce your tax bill this year.14Internal Revenue Service. Case Study 1, Wash Sales
Sales Inside a Retirement Account Work Differently
Stocks held inside a traditional 401(k) or traditional IRA follow separate timing rules. You can buy and sell within the account without triggering any tax. No capital gains tax applies on sales inside the account.15Office of the Law Revision Counsel. 26 US Code 401 – Qualified Pension, Profit-Sharing, and Stock Bonus Plans Instead, tax is deferred until you withdraw money, and the withdrawal is taxed as ordinary income at whatever bracket you fall into that year, regardless of whether the underlying growth came from long-term stock gains.16Office of the Law Revision Counsel. 26 US Code 408 – Individual Retirement Accounts
Roth IRAs and Roth 401(k)s go further. Because contributions went in with after-tax dollars, qualified distributions come out entirely tax-free, growth included. To qualify, you must be at least 59½ and at least five tax years must have passed since your first contribution to any Roth IRA.17Office of the Law Revision Counsel. 26 US Code 408A – Roth IRAs Pulling money out of either account type before age 59½ generally triggers a 10% early withdrawal penalty on top of any income tax owed, though limited exceptions exist for death, total disability, medical expenses over 7.5% of AGI, and up to $10,000 for a first-time home purchase from an IRA.18Internal Revenue Service. Retirement Topics, Exceptions to Tax on Early Distributions
How the Sale Gets Reported
Your brokerage sends you Form 1099-B after each tax year documenting every sale: the date you bought, the date you sold, the proceeds, and (for most securities purchased after 2011) your cost basis.19Internal Revenue Service. Instructions for Form 1099-B That information transfers to Form 8949, which separates short-term from long-term transactions and calculates the gain or loss on each. Totals from Form 8949 flow onto Schedule D of your Form 1040.20Internal Revenue Service. Instructions for Form 8949
Cost basis errors are among the most costly mistakes here. If your broker did not report basis to the IRS, or reported it incorrectly, you need to correct it on Form 8949 from your own records. Without accurate basis information the IRS can treat the entire sale proceeds as profit, producing a tax bill far larger than what you actually owe. Keep purchase confirmations and reinvestment records for every position until at least three years after you file the return reporting the sale.
State Tax Applies on Top
Federal is only part of the picture. Most states tax capital gains as ordinary income, with rates running from roughly 2% to over 13%. A handful of states impose no income tax at all, so no state-level capital gains tax applies there. Check your state’s revenue department for the rate and filing rules that apply where you live.