Tax-Lot Accounting Methods: FIFO, LIFO, and Specific ID

Equicurious Teamintermediate2026-03-22

Two investors own the same stock, bought at the same prices, and sell the same number of shares on the same day. One owes $7,400 in taxes. The other owes $1,500. The difference isn't a loophole or a special account — it's which tax lots they chose to sell. Tax-lot accounting is one of the highest-leverage, lowest-effort decisions in an investor's toolkit, and most people never change their broker's default setting.

TL;DR: Your broker defaults to FIFO (first-in, first-out), which often means selling your lowest-cost shares first and maximizing your tax bill. Switching to specific identification lets you choose which lots to sell, potentially saving thousands per year — but you need to understand the mechanics and make the election before the trade settles.

What Tax Lots Are (And Why Your Broker Tracks Them)

Every time you buy shares of a security — whether it's 500 shares in a single order or a $47 DRIP reinvestment — your broker creates a tax lot. Each lot records the purchase date, number of shares, and cost per share. When you sell, the IRS needs to know which lots you sold to determine your gain or loss and whether it's short-term or long-term.

Here's a concrete example. Over 18 months, you build a position in a stock:

LotDateSharesPriceTotal Cost
1Jan 2024100$40$4,000
2Jun 2024100$55$5,500
3Oct 2024100$35$3,500
4Jan 2025100$48$4,800

You now hold 400 shares. The stock is at $50. You want to sell 100 shares. Which lot you sell changes everything — from the size of your gain to whether it's taxed at 15% or 37%.

FIFO: The Default That Usually Costs You Money

First-In, First-Out sells your oldest shares first. It's the IRS default, and most brokers apply it automatically unless you specify otherwise.

Using our example, selling 100 shares at $50 under FIFO means you sell Lot 1 (bought at $40):

  • Gain: $50 - $40 = $10/share × 100 = $1,000
  • Holding period: Over 12 months → long-term capital gain
  • Tax at 15% rate: $150

That's not terrible. But FIFO becomes expensive when your earliest lots have the lowest cost basis — which is common in a stock that's appreciated over time. In a rising market, FIFO systematically sells your cheapest shares first, generating the largest possible gain.

The point is: FIFO is simple and predictable, but it optimizes for simplicity, not for tax efficiency. It's the right choice only if your oldest lots happen to have the highest cost basis.

LIFO: Selling the Newest Shares First

Last-In, First-Out sells your most recently purchased shares first. Under our example, selling 100 shares at $50 under LIFO means you sell Lot 4 (bought at $48):

  • Gain: $50 - $48 = $2/share × 100 = $200
  • Holding period: Less than 12 months → short-term capital gain
  • Tax at 37% rate (top bracket): $74

LIFO produced a much smaller gain ($200 vs. $1,000), but it's taxed at ordinary income rates because the shares were held less than a year. Even at the top bracket, the total tax is lower.

KEY INSIGHT: LIFO isn't always better than FIFO. If your newest shares have a low cost basis or short holding period, LIFO can generate larger short-term gains. The optimal method depends entirely on the specific lots in your account.

Important note on LIFO for securities: Unlike inventory accounting for businesses, the IRS does not formally recognize "LIFO" as a named method for securities. In practice, achieving LIFO treatment requires using specific identification and selecting the most recently purchased lots. Your broker may offer a "LIFO" button, but under the hood, it's implementing specific identification on your behalf.

Specific Identification: The Power Tool Most Investors Ignore

Specific identification lets you choose exactly which tax lots to sell for each transaction. This is where the real tax savings live. Using our example, you'd look at all four lots and pick the one that produces the best tax outcome.

Want to minimize current-year taxes? Sell Lot 3 (bought at $35, but now at $50):

  • Gain: $50 - $35 = $15/share × 100 = $1,500
  • Holding period: Over 12 months → long-term
  • Tax at 15%: $225

Wait — that's more than LIFO. But what if you have losses elsewhere to offset? Or what if you want to harvest a loss? Sell Lot 2 (bought at $55):

  • Loss: $50 - $55 = -$5/share × 100 = -$500 loss
  • Holding period: Over 12 months → long-term loss
  • Tax impact: $500 deduction against other gains, saving you $75-$185 depending on your bracket

Why this matters: specific identification turns every sale into a strategic tax decision rather than a mechanical default. Over a decade of investing, the cumulative difference between specific ID and FIFO can easily reach $10,000-$50,000 for a moderately active investor with a $500,000+ portfolio.

How to Elect Specific Identification

The IRS requires that you identify the specific lots at or before the time of sale, not after the fact. In practice:

  1. At your broker: Most major brokers (Schwab, Fidelity, Vanguard, E*TRADE) let you select specific lots during the trade entry process or immediately after. Look for "tax lot selection" in the order ticket.
  2. Written confirmation: The IRS technically requires "adequate identification," meaning you must specify which shares you're selling and receive confirmation from your broker. Electronic selection through your broker's platform satisfies this requirement.
  3. You can't change after settlement. Once the trade settles (T+1 for stocks), the lot selection is locked. If you forgot to specify, your broker's default method (usually FIFO) applies.

REMEMBER: If you want to use specific identification, change your broker's default lot selection method in your account settings now — before your next trade. Most brokers let you set "specific ID" or "tax-sensitive" as the default, which prompts you to select lots at trade time.

Average Cost: The Mutual Fund Exception

The average cost method divides your total cost basis by the total number of shares to produce a single average cost per share. This method is only available for mutual fund shares and certain dividend reinvestment plan shares — you cannot use it for individual stocks or ETFs.

Here's how it works. You invested $10,000 in a mutual fund over three purchases:

PurchaseSharesPriceCost
1200$25$5,000
2150$20$3,000
380$25$2,000

Total: 430 shares, $10,000 cost. Average cost: $10,000 ÷ 430 = $23.26/share.

If you sell 100 shares at $28, your gain is ($28 - $23.26) × 100 = $474, regardless of which shares the fund company actually redeems.

The Lock-In Problem

Once you elect average cost for a particular mutual fund, you're generally locked into that method for all future sales of that fund. Switching to specific identification requires written notice to your broker and only applies to shares acquired after the change. Shares already averaged cannot be "un-averaged."

The point is: if you hold mutual funds in a taxable account and might want lot-level control later, elect specific identification from the start. You can always mentally calculate the average, but you can't go backward from average cost to specific ID for shares already purchased.

The Four-Lot Comparison (Putting It All Together)

Using our original example — selling 100 shares at $50:

MethodLot SoldGain/LossTypeTax (37% / 15%)Net Tax
FIFOLot 1 ($40)+$1,000Long-term15%$150
LIFOLot 4 ($48)+$200Short-term37%$74
Highest CostLot 2 ($55)-$500Long-termDeduction-$75 to -$185
Lowest CostLot 3 ($35)+$1,500Long-term15%$225

The spread between the best and worst choice is $410 on a single 100-share trade. Scale that across a full portfolio over multiple years, and lot selection becomes one of the most impactful tax decisions you'll make.

What this means in practice: there is no single "best" method for all situations. The optimal lot depends on your current-year tax picture — do you need gains or losses? Short-term or long-term? Do you have capital loss carryforwards to use up? Specific identification lets you answer these questions trade by trade.

Broker Implementation: What to Check Today

Every major broker handles lot selection differently:

  • Fidelity: Default is FIFO. Change to "Tax-Sensitive" (their version of specific ID that auto-selects the most tax-efficient lot) in Account Settings → Cost Basis.
  • Schwab: Default is FIFO. Change via Account Settings → Cost Basis Method. Offers specific lot selection at trade time.
  • Vanguard: Default is average cost for mutual funds, FIFO for stocks/ETFs. Can be changed per account.
  • E*TRADE: Default is FIFO. Offers "Tax Optimizer" that uses specific identification to minimize current-year taxes.

The fix: log into your brokerage account right now and check your default cost basis method. If it's FIFO and you have a taxable account, switch to specific identification or your broker's tax-sensitive equivalent. This takes two minutes and applies to all future trades.

Action Checklist

Essential (do these today)

  • Check your default lot selection method at each broker — change FIFO to specific ID or tax-sensitive
  • If you hold mutual funds in taxable accounts, confirm whether you're using average cost or specific ID — if you haven't sold yet, elect specific ID now before you're locked in
  • Review your unrealized lots — know which lots are long-term, which are short-term, and what the cost basis spread looks like

High-Impact (before your next trade)

  • Practice selecting specific lots on a small trade — find the lot selection screen in your broker's order ticket
  • Document your lot selection strategy — write down rules like "always sell highest-cost long-term lots first" so you're consistent
  • Coordinate with your tax preparer — make sure they know which method you're using and that it matches your 1099-B reporting

Optional (for tax optimization enthusiasts)

  • Model different lot selections before large trades using a spreadsheet — compare FIFO, highest cost, and loss-harvesting scenarios
  • Set calendar reminders at 11 months post-purchase to flag lots approaching long-term status
  • Track lots across accounts if you hold the same security at multiple brokers

Your Next Step

Log into your primary brokerage account, navigate to account settings, and find the cost basis method selection. If it says "FIFO" or "First In, First Out," change it to specific identification (or your broker's tax-sensitive equivalent). This one change ensures you'll be prompted to choose the optimal lots on every future trade — and it takes less than two minutes.

Related Articles