How to Use FIFO Calculation

FIFO stands for First-In First-Out. When you sell shares, FIFO matches the sale with your oldest available purchase lot first.

For useful FIFO results, enter each buy and sell transaction with the correct date, number of shares, and price. Stock Events uses this transaction history to determine which shares were sold and which purchase lots remain.

How FIFO works

For example, imagine that you make these transactions without fees:

  • Buy 10 shares at $100 per share.
  • Buy another 10 shares at $200 per share.
  • Sell 10 shares at $300 per share.

With FIFO, the 10 shares bought at $100 are treated as the shares that were sold. The realized profit is $2,000: ($300 - $100) × 10 shares.

The remaining position contains the 10 shares bought at $200, so its average purchase price is $200 per share.

Selecting FIFO can change your realized profit or loss, the cost basis and average purchase price of your remaining shares, and your unrealized profit or loss. It does not change the transactions you entered.

How to select FIFO

  1. Open the Holdings tab.
  2. Select the small settings icon to the right of the period controls below the chart.
  3. Scroll to P/L Calculation.
  4. Select FIFO, labeled First-In First-Out.

The Holdings view recalculates after you select FIFO. You can return to the same menu at any time to choose another P/L calculation method.