17 mins read

How to Calculate Crypto Taxes with FIFO Step by Step

Last updated: November 05, 2026

Key Takeaways

  • FIFO is a first-in, first-out cost basis rule.
  • FIFO matches each disposal to the oldest open tax lot and calculates gain or loss per slice.
  • Keep records for identity, cost basis, and the date each lot left your control.
  • FIFO may not fit incomplete records, different local rules, or nonstandard transaction types.

FIFO tax calculation in How to calculate crypto taxes with FIFO step by step means you match each crypto sale or disposal with the oldest units you bought first. If you have a wallet full of buys on different dates, FIFO is the method that decides which tax lot gets used, which cost basis applies, and how much gain or loss you report. This is information, not financial advice; a qualified tax adviser should review your own situation because tax rules differ by country and change often.

Who this applies to, and what you need before you start

This applies to you if you bought crypto more than once, then sold, swapped, or spent some of it and need to trace the tax lots in date order. It also applies if you hold the same coin in several wallets or exchanges and need a consistent FIFO record across all of them. If you only made one purchase and one sale, the method is simpler, but the same logic still applies.

You need four things before you start: a complete transaction history, the purchase dates, the sale dates, and the amounts in units and in fiat value at each point. You also need to know your local tax year, because the reporting window is usually tied to that year rather than to the calendar month of each trade. The work becomes much easier if you already have a spreadsheet with columns for asset, quantity, date, fee, and fair market value at the time of each disposal.

The limit of FIFO is simple: it assumes the earliest coins out are the first coins sold, even if another lot would produce a smaller gain. That makes the math straightforward, but it is not the right fit for every taxpayer or every jurisdiction. If your country allows another method and your records are incomplete, do not guess. A tax adviser or accountant can tell you which method your local rules accept and how to handle a mixed history.

For a broader calculator workflow, this page sits alongside the crypto capital gains tax calculator hub. That hub helps with the overall reporting process; this page is for the FIFO method itself.

What FIFO means for crypto tax lots

FIFO means first in, first out, which is a cost basis ordering rule. A tax lot is one identifiable chunk of crypto acquired at a specific time and cost. When you dispose of 0.8 ETH, FIFO says you use the oldest available ETH lot first, then move to the next oldest lot only if the disposal is larger than the first lot.

The key idea is that each purchase creates a separate lot with its own purchase date and cost basis. If you bought 1 BTC on 3 January and another 0.5 BTC on 20 March, those are two lots even if they sit in the same wallet. Under FIFO, a later sale of 1.2 BTC would draw from the 3 January lot first, then 0.2 BTC from the 20 March lot.

This method matters because the gain is not calculated from a single average price. It is calculated lot by lot, using the basis attached to the units actually assigned to the sale. That means the order of matching can change the taxable result. A reader who mixes up FIFO with specific identification or average cost basis will get a different answer, which is why the method must be chosen and applied consistently where local rules require consistency.

The practical test is straightforward: if you can list the oldest units still held, then FIFO can be applied. If you cannot tell which purchase came first, or if your records are missing dates or quantities, the method stops being reliable. In that case the problem is not the arithmetic; it is the source data.

How to calculate crypto taxes with FIFO, step by step

You calculate crypto taxes with FIFO by lining up every disposal against the oldest open tax lot, then computing gain or loss for each matched piece. The process works best in a spreadsheet with one row per lot and one row per disposal.

  1. Gather every relevant transaction record. Pull all buys, sells, swaps, spends, and fees for the tax year and earlier open lots. Verify that each record shows the asset, quantity, purchase date or sale date, and fiat value. If a transaction has no date or no amount, the FIFO chain breaks.
  2. Separate acquisitions from disposals. Mark which entries create lots and which entries consume them. Check that transfers between your own wallets are treated correctly under your local rules, because some transfers are not disposals while others may need special handling. If you mislabel a transfer, the sale ledger will show a false gain.
  3. Sort all acquisition lots by purchase date, oldest first. Use exact timestamps when you have them; if your records only show dates, keep that format consistently. Verify the list starts with the earliest lot still available. If the ordering changes when you refresh the file, your sort is unstable.
  4. List each disposal by sale date and quantity. Put sales, swaps out, and crypto used for purchases in chronological order. Confirm the quantity disposed is recorded in the same units as the purchase lots. A 0.25 BTC sale cannot be matched correctly if one line is in BTC and another is in satoshis without conversion.
  5. Match the oldest available lot to the disposal. Allocate the sold quantity from the first lot until that lot is exhausted, then move to the next lot only if the sale is larger than the lot. Verify the quantities add up exactly. If the sale is 1.3 ETH and the oldest lot is 1 ETH, you should see 1 ETH matched to that lot and 0.3 ETH matched to the next.
  6. Assign cost basis to each matched slice. Use the purchase price plus eligible acquisition fees for that lot, converted into your reporting currency. Check that the cost basis per unit stays tied to the original purchase date, not the sale date. If the basis changes when the market moves, the file is using the wrong date.
  7. Compute proceeds for the disposal. Record the fiat value received at the sale date, less any selling fees if your tax rules allow that treatment. Verify the proceeds line uses the value at disposal, not the original buy price. If proceeds and basis are both taken from the purchase date, the result is wrong.
  8. Calculate gain or loss for each matched lot. Subtract allocated basis from allocated proceeds for every slice of the disposal. Check that each line shows either a gain or a loss and that the totals reconcile back to the whole sale. If the sum of the slices does not equal the disposal total, a lot was skipped or duplicated.
  9. Carry the unused remainder forward. If a lot was only partly used, leave the remaining units open for the next sale. Verify the remaining quantity is correct after each matching step. If the file says a lot is fully used when 0.05 ETH still remains, the next sale will be overstated.

A small worked pattern helps: if you bought 2 units on 10 January and 3 units on 5 February, then sold 4 units on 20 March, FIFO consumes the 2 January units first and 2 of the February units next. The remaining 1 February unit stays open as a later lot. The gain or loss is the sum of the two matched slices, not one blended figure unless your local tax process explicitly reports it that way.

What records do I need for FIFO crypto taxes?

You need records that prove each lot’s identity, its cost basis, and the date it left your control. At minimum, keep the purchase date, sale date, quantity, asset name, fiat value at acquisition, fiat value at disposal, and any fees tied to the trade. If you used multiple exchanges, keep the source statements for each platform so the chronology can be rebuilt.

The most common missing item is the purchase timestamp. Without it, you cannot reliably say which lot is oldest. The second common gap is fee treatment: some records show the trade price but not the fee, which can distort cost basis if the fee should be included under your local rules. Keep deposit and withdrawal records too, because they help distinguish a real taxable event from a simple wallet transfer.

A clean file usually has one row per transaction and one extra column for lot status: open, partially used, or closed. That status matters because FIFO is cumulative. A lot bought in January may still be partially open in November if only part of it was disposed of. If you rely on screenshots alone, the process becomes fragile; exports in CSV or similar tabular form are easier to audit and cross-check.

Where the law or tax authority requires a more formal record, follow that standard rather than a personal spreadsheet format. Different countries and even different tax offices can treat crypto records differently, so the exact retention period and format are not universal. If your history involves staking rewards, airdrops, or business inventory treatment, ask a qualified adviser before assuming FIFO alone solves the recordkeeping problem.

When FIFO stops being the right tool

FIFO stops being the right tool when your records are incomplete, your local rules require a different method, or the transaction type does not fit a simple purchase-and-sale pattern. In those cases the calculation can be misleading even if the spreadsheet looks tidy.

Missing purchase dates: you cannot establish the oldest lot with confidence — rebuild the history from exchange exports, wallet logs, and blockchain records before you calculate any gain.
Mixed asset types in one record: swaps, wrapped tokens, and bridge transactions can blur what is actually being disposed of — split them into separate events first.
Transfers mistaken for sales: moving coins between your own wallets is not always a disposal — correct the classification or your gains will be overstated.
Hard forks, airdrops, or staking rewards: these often create new tax lots under separate rules — do not force them into a basic FIFO sale ledger without checking local treatment.
Business or inventory treatment: some taxpayers do not report crypto as a capital asset — stop using a personal FIFO worksheet and get the correct reporting framework.
Large, multi-year histories with gaps: a 2-year or 5-year transaction trail can hide unmatched lots and duplicate entries — use professional review before filing.

The consequence of getting this wrong is usually not just a math error; it is a filing position that may not match your jurisdiction’s reporting rules. If you are unsure whether a transaction is taxable, treat the uncertainty as a research problem, not a spreadsheet problem. A tax adviser can tell you whether FIFO applies to that event at all.

The mistakes people make with FIFO, and what they cost

The most common FIFO mistakes are simple, and each one changes the gain calculation in a predictable way. The good news is that the fixes are mechanical once you know where the error starts.

  1. Using the wrong sort order. If the lots are sorted newest first, the calculation becomes LIFO by accident. The consequence is a different gain or loss than FIFO would produce. The fix is to sort by purchase date ascending and lock the column before matching sales.

  2. Ignoring partial lot usage. A sale of 1.7 units against a 2-unit lot leaves 0.3 units open. If the remaining amount is not carried forward, the next sale will consume the same units twice. The correct alternative is to update the open balance after every disposal.

  3. Mismatching units and currencies. If one line is in ETH and another is in USD, or if a fee is stored in the wrong currency, the result is meaningless. The fix is to convert everything to the reporting currency at the transaction date and keep the original unit column too.

  4. Leaving fees out of basis or proceeds without checking the rule. Fees can change the taxable result materially, but treatment varies by jurisdiction. The consequence of a blank fee column is an inflated or understated gain. The correct alternative is to record fees separately and apply the local rule consistently.

  5. Combining separate wallets without tracing transfers. If coins move from an exchange to a cold wallet and back, a bad ledger can create fake buys and sells. The consequence is duplicate taxable events. The fix is to label internal transfers and exclude them where the rules allow.

The pattern here is always the same: FIFO is not hard because of the formula; it is hard because the timeline has to be exact. If the date order, quantity, and basis are correct, the arithmetic is usually straightforward. If any one of those three is wrong, the result can misstate the tax position.

What changes when the transaction history gets messy?

The standard FIFO method needs adjustment when the history includes nonstandard events, missing data, or multiple venues. A clean 2024 spot-trading history is one thing; a three-year trail with swaps, bridges, and partial exports is another.

If you have the same asset across several exchanges, first consolidate the records into one chronology. Do not merge them by wallet label alone. The relevant question is the order of acquisition, not the platform where the coin sat. If you moved 0.4 BTC from one exchange to another, that move may be a transfer rather than a taxable sale, but you still need the movement record to prevent a duplicate lot.

If the asset underwent redenomination, token migration, or a chain split, the old and new units may not map one-to-one under a simple FIFO ledger. In that case, the lot history needs a separate event line before the next sale can be matched. The same is true if you received a token distribution that your local rules treat as income first and then as a new basis event. A generic FIFO worksheet often fails here because it assumes every lot starts with a plain purchase.

For very small quantities or rounding issues, keep the same decimal precision throughout the file. A 6-decimal or 8-decimal trading environment can produce tiny leftovers that look like errors when they are really rounding effects. The safe approach is to use the highest precision your records support and only round at the reporting stage if the tax form requires it.

If any of these edge cases changes the character of the event, stop forcing the transaction into the basic FIFO pattern. A qualified tax professional can tell you whether the event creates a new lot, a separate income item, or a non-taxable transfer.

Drafted with AI; not yet reviewed by a person.

Leave a Reply

Your email address will not be published. Required fields are marked *