FIFO vs LIFO vs HIFO: which crypto cost basis method is right for you? (2026)
When you have bought the same coin many times at different prices, which one are you "selling"? The answer — your cost basis method — can swing your tax bill by thousands. Here is how the six methods differ and which your country allows.
Why the method matters so much
Your cost basis is what you originally paid for a coin; your gain is the sale price minus that cost basis. Simple — until you have bought the same coin many times at different prices. If you bought 1 BTC at $20,000 and another at $60,000, then sell 1 BTC at $80,000, your gain is either $60,000 or $20,000 depending on which BTC you are deemed to have sold. That choice is the cost basis method, and across a year of trading it can change your taxable gain — and your tax bill — by thousands. In many countries the method is not a choice at all; it is mandated.
FIFO — First In, First Out
FIFO assumes the first coins you bought are the first ones you sell. In the example above, FIFO sells the $20,000 BTC first, producing a $60,000 gain. In a rising market FIFO tends to produce larger gains (you sell the oldest, cheapest lots first) — but it is simple, transparent, and the default or mandatory method in many places. Spain's AEAT requires FIFO. Germany uses FIFO (per-wallet). Italy applies FIFO to acquisitions from 2023 onward.
LIFO — Last In, First Out
LIFO assumes the most recently bought coins are sold first. In the same example, LIFO sells the $60,000 BTC, cutting the gain to $20,000. LIFO can reduce gains in a rising market, but it is not permitted for crypto in many jurisdictions — Spain and much of the EU require FIFO. Treat LIFO as available only where your local rules explicitly allow it.
HIFO — Highest In, First Out
HIFO always sells the highest-cost lot first, regardless of when it was bought, which minimises the taxable gain on every sale. It is the most aggressive optimisation method and can meaningfully lower a bill for active traders. It is not allowed in FIFO-mandated countries like Spain, Italy, or Germany, but it is a legitimate option in more flexible systems such as the US (where taxpayers can use specific identification).
ACB, Share Pooling, and Spec ID — the country-specific methods
Three more methods matter because entire countries are built on them. Canada requires the Adjusted Cost Base (ACB) — a weighted-average cost per coin, recalculated on each purchase. The UK requires Share Pooling (Section 104): all units of an asset sit in a single pool at an averaged cost, with special "same-day" and "30-day bed-and-breakfasting" rules layered on top. Specific Identification (Spec ID) lets you nominate exactly which lot you are selling, and is available to US investors who keep detailed records — it underpins strategies like HIFO.
Which method should you use?
Mostly, your country decides for you: FIFO in Spain, Germany, and Italy (from 2023); Share Pooling in the UK; ACB in Canada; more flexibility (FIFO, Spec ID, HIFO) in the US; and FIFO or specific identification in Australia. Where you do have a choice, the "best" method depends on your trades and whether the market rose or fell over your holding period — there is no universal winner, and switching methods year to year is usually not allowed. The right move is to apply your jurisdiction's required method correctly and consistently, and to see the numbers before you file.
How Taxxy applies all six methods
Taxxy ships all six cost basis methods — FIFO, LIFO, HIFO, ACB, UK Share Pooling (Section 104 with the 30-day rule), and Spec ID — and applies the correct one for your country automatically, tracked per wallet for accuracy. Where your jurisdiction allows a choice, you can compare methods side by side to understand the impact before you file. Combined with minute-level exchange pricing, that means your cost basis — the foundation of every gain calculation — is both compliant and precise.