

Stocks represent ownership in a company. Learn what stocks are, how they work, and the two ways investors make money from them.

Capital gains tax applies when you sell investments for a profit. Learn how it works, current 2025-2026 rates, and strategies to reduce what you owe.

Traditional IRA, Roth, 401(k), brokerage, pension, Social Security — each gets taxed differently in retirement. Here's the complete breakdown.

Founder of Arcanomy
Ph.D. engineer and MBA writing about wealth psychology, financial clarity, and why most money advice misses the point.
Subscribe for more insights, tips, and updates, straight to your inbox.
We respect your privacy and will never share your information.
Roughly 62% of American adults own stock. Most of them have no idea how their investments are taxed.
That's not a character flaw. The tax code treats capital gains, dividends, and interest income differently, then layers on separate rules depending on which account holds the investment. A share of Vanguard's VTI behaves one way in a Fidelity brokerage account and a completely different way inside a Roth IRA. Same investment, different tax universe.
This guide untangles all of it.
The 30-Second Version: Investment income comes in three flavors (capital gains, dividends, interest), each taxed at different rates. The account you use (brokerage, 401(k), Roth IRA, HSA) changes the rules dramatically. Picking the right account for the right investment can save you thousands every year.
Every dollar your portfolio generates falls into one of three buckets. Each has its own tax treatment.
When you sell an investment for more than you paid, the profit is a capital gain. The IRS cares deeply about one thing: how long you held it.
Short-term capital gains apply to assets held one year or less. These are taxed at your ordinary income rate, which can run as high as 37%.
Long-term capital gains kick in after you've held an asset for more than one year. The rates are gentler: 0%, 15%, or 20%, depending on your taxable income.
Here's where it gets real. Meet Priya, age 34, a project manager in Denver earning $75,000. She bought shares of an S&P 500 index fund for $5,000 and sold them for $8,000. Her gain: $3,000.
If Priya held those shares for 11 months, that $3,000 is taxed at her ordinary rate of 22%. She owes $660.
If she held for 13 months, the same $3,000 is taxed at the long-term rate of 15%. She owes $450.
Two extra months saved her $210. On larger sums, the difference is staggering.
For a deep dive into how stock sales, dividends, and holding periods interact, see our guide to taxes on stocks: what you owe when you sell, hold, or collect dividends.
Companies distribute a portion of profits to shareholders as dividends. The tax rate depends on whether the dividend is "qualified" or "ordinary."
Qualified dividends get the same favorable rates as long-term capital gains (0%, 15%, or 20%). Most dividends from U.S. companies qualify, provided you hold the stock for at least 61 days during a specific window around the ex-dividend date.
Ordinary (non-qualified) dividends are taxed at your regular income rate, up to 37%. REIT dividends, money market fund distributions, and dividends on stocks you haven't held long enough all fall here.
We break down the holding period math and rate tables in detail in how dividends are taxed: qualified vs. ordinary rates.
Interest from bonds, CDs, savings accounts (like those at Marcus by Goldman Sachs or Ally Bank), and Treasury securities is generally taxed as ordinary income. No special rates. No holding period magic.
One exception: interest from municipal bonds is usually exempt from federal income tax, and sometimes state tax too. That's why munis are popular with investors in higher brackets. (It's also why your uncle who worked at the county assessor's office for 30 years won't shut up about them at Thanksgiving.)
The investment itself is only half the equation. Where you hold it transforms the tax picture.
| Feature | Taxable Brokerage | Traditional 401(k)/IRA | Roth 401(k)/IRA | HSA |
|---|---|---|---|---|
| Tax on contributions | None (after-tax money) | Deductible (pre-tax) | None (after-tax) | Deductible (pre-tax) |
| Tax on growth | Annually on gains/dividends | Tax-deferred | Tax-free | Tax-free |
| Tax on withdrawal | Only on new gains | Ordinary income rates | $0 (if qualified) | $0 (for medical expenses) |
| Best for | Flexibility, no income limits | High earners wanting deductions now | Expecting higher tax rates later | Medical costs + stealth retirement |
A few things jump out from this table.
In a taxable brokerage account at Schwab or Fidelity, every dividend payment and every profitable sale triggers a tax event that year. Buy VTI, collect $2,000 in dividends, and you owe tax on those dividends even if you reinvested them automatically. The IRS treats reinvested dividends the same as cash in your hand.
In a Traditional 401(k) or IRA, contributions come out of your paycheck before taxes. Growth is invisible to the IRS until you withdraw. Then every dollar comes out taxed as ordinary income. There's no special capital gains rate in retirement. A dollar of growth and a dollar of contributions are treated identically.
In a Roth IRA or Roth 401(k), you've already paid income tax on contributions. In return, qualified withdrawals (after age 59½ and the 5-year rule) are completely tax-free. Capital gains, dividends, interest: zero tax. For more on how this works in practice, see do you pay capital gains tax in a Roth IRA?
The HSA (Health Savings Account) is the only account with a triple tax advantage: deductible contributions, tax-free growth, and tax-free withdrawals for qualified medical expenses. After age 65, non-medical withdrawals are taxed like a traditional 401(k), but you still got two tax breaks along the way. Our comparison of tax-advantaged accounts walks through the prioritization order.
Here's a concept most beginner guides skip. It matters.
Capital gains don't exist in a vacuum. They stack on top of your ordinary income to determine which rate you pay.
Back to Priya. Her $75,000 salary minus the $15,750 standard deduction gives her $59,250 in taxable ordinary income. For single filers in 2025, the 0% long-term capital gains bracket covers taxable income up to $48,350. Priya already blew past that threshold with her salary alone.
So her $3,000 long-term gain sits entirely in the 15% bracket. She owes $450.
But what if Priya earned only $40,000? After the standard deduction, her taxable ordinary income would be roughly $24,250. That leaves about $24,100 of room in the 0% capital gains bracket. Her $3,000 gain would be taxed at 0%. She'd owe nothing.
This is why retirees with modest pension income sometimes pay zero capital gains tax. It's not a loophole. It's just the math.
High earners face an additional 3.8% Net Investment Income Tax (NIIT) on capital gains, dividends, and interest if their modified adjusted gross income exceeds $200,000 (single) or $250,000 (married filing jointly). These thresholds are not indexed for inflation, which means more taxpayers hit them every year.
For someone earning $220,000 with a $10,000 stock gain, the NIIT adds $380 to their tax bill. On a $100k gain, it's $3,800. Worth knowing before you sell.
Lost money on an investment? That loss has value.
Capital losses offset capital gains dollar for dollar. If you sold one stock for a $5,000 gain and another for a $5,000 loss, your net gain is zero. No tax.
If your losses exceed your gains, you can deduct up to $3,000 per year against ordinary income. Unused losses carry forward indefinitely. Someone who lost fifteen grand in a bad year can spread that deduction over five years.
This is the foundation of tax-loss harvesting, where you strategically sell losing positions to offset winners. Just watch out for the wash sale rule: buying a "substantially identical" security within 30 days before or after the sale disallows the loss.
Yes, there are edge cases where this gets messy. Inherited property is one. A messy divorce is another. Life is complicated and tax law is worse.
This trips up more beginners than almost anything else.
You set up automatic dividend reinvestment (DRIP) in your Fidelity brokerage account. Apple pays you $200 in dividends. Those dollars automatically buy more Apple shares. You never see cash. You never touched it.
You still owe tax on that $200.
The IRS treats it as if you received $200 in cash and then chose to buy more stock. Two separate events. This doesn't apply inside an IRA or 401(k), where everything grows tax-deferred or tax-free. But in a taxable account, reinvested dividends generate a tax bill every single year.
Check your 1099-DIV in February. Box 1a shows total dividends. That's your number.
Check your holding periods before selling. If you're within a few weeks of the one-year mark, waiting can cut your tax rate from 22% (or higher) down to 15%. Use your brokerage's "tax lot" view to see purchase dates.
Put high-turnover investments in tax-advantaged accounts. Actively managed funds, REITs, and bond funds generate the most taxable events. Shelter them inside your 401(k) or IRA. Hold tax-efficient index funds (like Vanguard's VTI or VXUS) in your taxable brokerage.
Don't forget reinvested dividends on your tax return. If you use DRIP in a taxable account, those dividends are taxable income. Your 1099-DIV has the details.
Run the numbers with our compound interest calculator to see how tax-deferred growth changes your long-term wealth. The difference between taxable and tax-free compounding over 30 years is often six figures.
Harvest losses before year-end. If you have losing positions and winning positions, selling losers can offset gains and reduce your bill. Just avoid triggering the wash sale rule by repurchasing within 30 days.
For a broader view of how to build a diversified portfolio that accounts for tax efficiency, see our investing fundamentals guide. And if you're filing taxes and wondering when capital gains tax is actually due, we cover the timing and deadlines too.