Logo Stock Sale Optimizer

Keep More of Your Money. Keep All of Your Data.

Selling part of a position? Accepting your broker's default sale method can cost you thousands in unnecessary taxes. Find the most tax-efficient lots to sell in seconds—completely in your browser.

Get Your Data From Your Broker

To sell the lots that minimize your taxes, we need your Detailed Cost Basis. Download this as a CSV file from your brokerage portal.

Look for these terms in your portal:

Lot Details Unrealized Gain/Loss Cost Basis Detail

⚠️ Avoid "Purchase History" or "Transaction History": These usually include shares you've already sold. To get an accurate plan, we only need the unrealized lots you still own today.

Your CSV must look like this:
Symbol Date Qty Price
XYZ 01/12/23 50.0 $142.10
XYZ 04/22/24 12.5 $165.30

Each row represents a specific purchase or vest event for the same symbol.

Your data stays private. The optimization happens entirely in your browser—nothing is ever uploaded to a server.

Generate Your Sales Plan

For partial sales only. Selling all shares? The total gain/loss is the same.

📁

Click to upload or drag & drop

Drag & drop the CSV file you downloaded from your broker.

$
$

Why Lot Selection Matters

When you sell stock or an ETF, you’re not just selling “shares.” You’re selling specific tax lots—blocks of shares purchased on different dates at different prices.

💎

Equity Compensation

RSUs, ESPPs, and Stock Options create new lots with every vest or purchase—often quarterly. Years of participation means dozens of lots at different prices.

🔄

Dividend Reinvestment

DRIP automatically reinvests dividends, creating a new micro-lot every payout. A decade of reinvestment can mean 40+ lots you didn't know you had.

FIFO

First In, First Out. You sell your oldest shares first. Often results in long-term capital gains, but can trigger large tax bills if your early cost basis was very low.

Often the broker default if you don't specify.

LIFO

Last In, First Out. You sell your newest shares first. This often minimizes gains if you bought recently at higher prices, but might trigger higher short-term tax rates.

Specific Lot

The Smart Choice. You pick the exact lots to sell. This allows you to harvest losses, offset gains, and intentionally manage your tax bracket.

"Lot selection mainly matters when you sell only part of a position. If you sell all shares at once, the total gain/loss is the same regardless of which lots are assigned."

To use a specific-lot strategy, you generally need to choose lots at the time you place the trade (or by your broker’s deadline).

Real-World Scenarios

Same sale, same stock, same day—wildly different tax outcomes.

Averaging Down

FIFO Wins

You bought high, then averaged down. After a partial rebound, selling your oldest shares (bought at the peak) realizes a loss to offset other gains.

FIFO (Oldest) $0 Tax Due
LIFO (Newest) $700 Tax Due

Long-Term Growth

LIFO Wins

Your stock has risen steadily. Selling newer shares (bought near today's price) means a smaller gain and more cash in your pocket.

FIFO (Oldest) $900 Tax Due
LIFO (Newest) $175 Tax Due

Recent Pullback

LIFO Wins

You bought more near the top, then the price dropped. Selling the newest shares (bought high) harvests a loss; FIFO would force you to pay tax on old gains.

FIFO (Oldest) $600 Tax Due
LIFO (Newest) $0 Tax Due

The Dip Buyer

FIFO Wins

You bought during a dip at a low price. Selling those newest shares (bought cheap) triggers a massive gain. FIFO sells older shares with a higher cost basis instead.

FIFO (Oldest) $150 Tax Due
LIFO (Newest) $1,575 Tax Due

Our Approach: Tax-Smart Pairing

Specific Lot Selection

$0 Tax vs $1,225

You need to raise $20,000 by selling 200 shares at $100. Your portfolio has four lots—some with gains, some with losses. FIFO blindly sells the oldest; LIFO blindly sells the newest. Our optimizer picks strategically—here, pairing a small gain with a matching loss so they cancel out.

FIFO Default
$825 Tax
LIFO Default
$1,225 Tax
Specific Lot
$0 Tax

Markets are volatile—but that works in your favor. You likely have a mix of winners and losers to offset each other.

CSV Cleanup Required

We detected rows that don't appear to be data. Would you like to remove them?

Map Your CSV Columns

We couldn't automatically match all columns. Please select the correct fields.