Intermediate · 10 min read

Cost Basis Methods for Crypto Taxes: FIFO, LIFO, and HIFO Explained

The same crypto sale can generate wildly different taxable gains depending on which accounting method calculates it. Understanding FIFO, LIFO, and HIFO for crypto taxes is one of the few legal levers holders actually have over their own tax bill.

Nadia OkoroNadia OkoroPolicy & Consumer Editor · Regulation, tax, stablecoins and the products retail users hold
Cost Basis Methods for Crypto Taxes: FIFO, LIFO, and HIFO Explained
The short answer

Cost basis is what you paid for the units you disposed of, and the method that decides which units were sold changes the tax owed. FIFO sells the oldest first, LIFO the newest, HIFO the highest-cost — which reports the smallest gain now while leaving low-cost units in the pool for later. Method availability is set by your jurisdiction, and any choice must be supported by records made at the time.

Nobody buys their entire crypto position at a single price on a single day, which is precisely why cost basis methods for crypto taxes matter as much as they do. Most holders accumulate over months or years, buying at different prices each time, and when they eventually sell a portion of that position, tax authorities need a rule for deciding exactly which of those purchases is being sold. That rule is the cost basis method, and the choice between the three common ones — FIFO, LIFO, and HIFO — can genuinely swing a reported gain by tens of thousands of pounds on an identical sale, using identical coins, on an identical day. It's one of the few places in crypto tax where the paperwork decision is entirely within the holder's control.

Why the method matters at all

Capital gains tax is calculated on the difference between what you sold an asset for and what you originally paid for it — the cost basis. The complication arrives the moment you've bought the same asset more than once at different prices, because a sale of, say, 0.5 BTC now has to be matched against specific prior purchases to know what the original cost actually was. If you bought 1 BTC at £20,000 and later another 1 BTC at £50,000, and you now sell 1 BTC when the price is £60,000, your taxable gain is either £40,000 or £10,000 depending entirely on which of those two purchases the tax authority considers you to have sold. Same coin, same sale price, same holder — a £30,000 difference in reported gain purely from an accounting choice.

FIFO: first in, first out

FIFO assumes the coins you sell are always the oldest ones you own — the first purchased are the first sold. In a market that has generally trended upward over long periods, this tends to mean the coins being sold have the lowest cost basis, since they were bought earliest and typically cheapest, which usually produces the largest reported gain and the largest tax bill for a given sale. FIFO's appeal isn't tax minimisation — it's simplicity and default legitimacy. It's the method tax authorities in many jurisdictions apply by default if a holder doesn't actively elect an alternative, and it requires the least record-keeping discipline because it doesn't ask the holder to select specific lots at the point of sale.

LIFO: last in, first out

LIFO flips the assumption, treating the most recently acquired coins as the ones being sold first. In a rising market, this generally produces a smaller reported gain than FIFO on any given sale, because the most recent purchase is usually the most expensive, and a higher cost basis means a smaller taxable difference. The catch is that LIFO isn't accepted for crypto by every tax authority — the US IRS, for instance, only permits it for crypto under specific identification rules with careful contemporaneous record-keeping, not as a blanket default the way FIFO effectively is, so it's worth confirming local rules apply before assuming it's available.

HIFO: highest in, first out

HIFO takes a different approach entirely, selling whichever specific lot had the highest cost basis first, regardless of when it was purchased. This is, mechanically, the method that minimises reported gains — and therefore tax owed — in the near term, for the straightforward reason that it deliberately selects the most expensive prior purchase to offset against the sale price. Its cost is administrative: HIFO requires meticulous, lot-by-lot record-keeping to justify which specific units were sold, since it isn't matching purchases in any simple chronological order, and it demands the kind of specific identification documentation that tax authorities expect to see if a return is ever queried.

The trade-off HIFO doesn't erase

It's worth being precise about what HIFO actually achieves, because it's frequently misunderstood as making a gain disappear rather than merely deferring it. Selling the highest-cost lot first minimises the gain on that specific sale, but it also leaves the lower-cost, higher-gain lots sitting in the portfolio for a future sale — the tax liability hasn't vanished, it's been pushed down the road to whenever those remaining coins eventually get sold. For a holder planning to sell down a position gradually over several years, this deferral has genuine value, effectively functioning as an interest-free delay on part of the tax bill. For a holder who's about to liquidate the entire position regardless, the total tax paid across all the sales combined ends up roughly identical no matter which method was used — HIFO just changes the timing and sequencing of when each portion of the gain gets recognised.

Specific identification versus averaging

A related but distinct question is whether a jurisdiction requires or permits specific identification at all, as opposed to a pooled average-cost method. The UK, for instance, uses a share-pooling approach for most crypto holdings rather than FIFO or HIFO in the conventional sense — same-day and 30-day rules aside, most holdings of a given asset are averaged into a single pooled cost basis, meaning the FIFO/LIFO/HIFO distinction that dominates US crypto tax planning is largely inapplicable to UK holders in the way it's often discussed online. This is the single most common source of confusion for holders reading US-focused crypto tax content while filing under a different jurisdiction's rules, and it's worth checking which regime actually applies before assuming any of these methods are available at all.

Practical steps before assuming any method is optimal

Whichever jurisdiction's rules apply, the method choice generally has to be applied consistently once elected, not cherry-picked sale by sale to whatever produces the lowest number that particular year — most tax authorities that permit a choice expect it to be declared and used consistently going forward. Good record-keeping is the real prerequisite behind all of this: exact purchase dates, exact amounts, and exact prices in local currency at the time of each transaction, across every wallet and exchange used, because no accounting method can be applied correctly to records that don't exist. Crypto tax software that ingests exchange and wallet history directly has become close to essential for anyone with more than a handful of transactions spread across multiple platforms, if only because reconstructing years of scattered on-chain and exchange activity by hand at filing time is where most reporting errors actually originate.

FAQ

What is cost basis in crypto?
What you paid for the units you disposed of, including fees. The gain is the proceeds minus that figure, so the method that picks which units were sold changes the tax owed.
Which cost basis method is best?
HIFO usually reports the smallest gain now by matching the highest-cost units first, but it leaves low-cost units in the pool for later. The lowest bill this year is not always the lowest overall.
Can I choose my cost basis method?
Only where your jurisdiction allows it, and the choice must be supported by records made at the time. Some countries mandate a method outright — the UK uses pooling with same-day and 30-day matching rather than FIFO.
What is specific identification?
Naming exactly which units you sold rather than applying a formula. It gives the most control and requires per-lot records showing acquisition date, quantity and price.