Capital Gains Calculator for Crypto and Shares (FIFO, LIFO, HIFO, 12-Month Discount)
Compute capital gains from a list of buys and sells with your choice of cost matching and a holding-period discount.
Use the tool
Why this tool exists
Capital gains tax needs each sale matched to the purchases it disposes of. This calculator takes a CSV of dates, buy or sell, asset, quantity, price per unit and fee; matches sales to buy lots by FIFO, LIFO or highest cost first; adds fees to the cost base and deducts them from proceeds; and reports gain or loss per lot, whether the lot qualified for a discount (default 50% after 365 days, as for Australian individuals), losses applied before the discount, the net capital gain and what you still hold.
Tax rules differ by country and over time. Set the discount to 0 for rules without one, and treat crypto-to-crypto swaps as a sell plus a buy at market value. It is a calculator, not tax advice or a tax return.
How to use it
- Paste the CSV: date,type,asset,quantity,price,fee.
- Choose FIFO, LIFO or HIFO and set the discount days and percentage.
- Review each disposal and the net capital gain.
Frequently asked questions
Which method should I use?
Use the one your tax authority allows. Australia allows choosing a method if you keep consistent records.
Are losses handled?
Yes, applied first to gains without discount, then to discountable gains, before the discount.
Is my data private?
Yes. Everything is calculated in your browser.