Live
Loading prices…
Tax

Crypto cost basis method calculator

FIFO, LIFO or HIFO — the method you pick decides which coins you “sold” and can swing this year's tax bill by thousands. Load the history you already export and see all three at once, including the part most calculators hide: how much of the saving is only deferred to a later year.

US specific-identification · other countries' mandated methods flagged · nothing leaves your browser

1 · Load your transaction history

🔒 Never leaves your browser

Drop a CSV here, or

Or paste CSV text
Free calculators48 free calculators — no signupFinance, health, conversions and everyday math. Instant answers, nothing to install.Open CalcLumen

The saving that is really a loan from your future self

Say you bought one bitcoin at $20,000 years ago and another at $60,000 last quarter, then sold one for $65,000. FIFO sells the cheap coin and reports a $45,000 gain. HIFO sells the dear one and reports $5,000. The $40,000 difference looks like money saved — but you still own one bitcoin either way, and under HIFO the coin you kept carries the $20,000 basis instead of the $60,000 one. Sell it later and that $40,000 comes back as gain. The tax moved; it did not vanish. This tool puts the remaining cost basis next to the tax for exactly this reason, so you are comparing the whole picture and not just the flattering half.

When deferring is still the right call

Deferral is not a trick — it is often the correct move. A dollar of tax paid next year is cheaper than one paid now, so all else equal, later is better. HIFO also shines when it turns a sale into a loss you can set against other gains this year, or when you expect to be in a lower bracket later, or simply need the cash the lower bill frees up. What matters is deciding it on purpose. The one case where a method genuinely saves rather than defers is when you never sell the remaining lots — you hold them past death for a step-up, donate them, or move somewhere they are not taxed. Short of that, treat the current-year number as timing, not magnitude.

You can only choose in the US — and only with records

Picking a method is a US specific-identification feature. To use anything other than FIFO the IRS expects you to have identified the exact units at the time of each sale, with their acquisition dates, costs, and the value on the day you sold. Reconstructing HIFO in April for trades you did not document as you went is not what the rule allows. Since 2025 basis is also tracked per wallet and per account rather than in one pool, and brokers report it on Form 1099-DA — so a method applied across your whole history can disagree with what the IRS already has. Everywhere else in this tool the country mandates a single method and the comparison collapses to one honest number.

What this does not do

It pools each asset rather than tracking basis per wallet, so it will not match a per-account 1099 line for line. It applies the single rate you enter instead of running your full bracket, the $3,000 net-loss offset against ordinary income, or state tax. It does not know your other income, your carried-forward losses, or any trade missing from the file. And it does not judge whether selling is a good investment — only what each method does to the tax. For the complete position, run the same file through the crypto tax report, and see the country guides for the rules behind every figure.

Frequently asked questions

What do FIFO, LIFO and HIFO actually mean?

They are rules for deciding which coins you sold when you own several bought at different prices. FIFO (first in, first out) sells your oldest coins first. LIFO (last in, first out) sells your newest. HIFO (highest in, first out) sells whichever cost you the most, regardless of when you bought it. The coins that leave your account are identical either way — only the cost basis assigned to the sale changes, and with it the gain you report.

Which method pays the least crypto tax?

Usually HIFO for the current year, because selling your highest-cost coins first leaves the smallest gain — sometimes even a loss. But 'least this year' is not 'least ever'. Selling your dear coins now leaves your cheap ones on the books, and those carry a larger gain when you finally sell them. This tool shows both numbers so you can see the trade rather than just the headline.

Does HIFO save tax or just defer it?

Mostly defer. Your total cost basis across all your coins is fixed — whatever you do not use against this year's sales stays attached to the coins you keep and is taxed when you sell those. HIFO front-loads the basis, so it lowers this year's bill and raises a later one. That is genuinely valuable if you expect a lower rate later, need cash now, or want to bank a loss — but it is not free money, and any tool that shows only the current-year saving is telling you half the story. The 'cost basis left' column here is the other half.

Can I really choose my cost basis method for crypto in the US?

Yes, under the IRS specific-identification rules — but only if you can identify the exact units at the time of sale, with records showing the acquisition date, cost, and the date and value at disposal. If you cannot, the IRS default is FIFO. Since 2025 the US also requires per-wallet, per-account basis tracking rather than one universal pool, so a method chosen across everything may not match what your broker reports on Form 1099-DA. Treat this as a planning estimate, then confirm with your records and a professional.

Can I use LIFO or HIFO outside the United States?

Generally no. Most countries mandate a single method: the UK uses share pooling with same-day and 30-day rules, Canada uses the adjusted cost base (a moving average), Germany, Australia, Ireland and others require FIFO. There is no method to choose, so there is nothing to compare — pick your country in the tool and it will say so and show your single lawful result.

Is my transaction data uploaded anywhere?

No, and there is nowhere for it to go. This site is static files with no server and no database. Your CSV is read by your browser, every method is computed in the same tab, and closing it discards everything. Nothing about your trades leaves the device.

Does this replace tax software or an accountant?

No. It is an estimate from your file using published rules. It pools each asset rather than tracking per-wallet basis, it uses the single rate you enter instead of your full bracket, and it does not know your other income, carried-forward losses or anything your file leaves out. Use it to see whether choosing a method is worth pursuing, then file with proper records.

Related