Skip to content
Menu

Tax on shares, funds or crypto you've sold

When you sell part of a holding you bought over time, its cost is the average cost of everything you hold, not what you paid for the ones you sell. Enter your holding and the sale to see the tax.

What you held before the sale
Type of holding

One holding at a time: shares in one company, units in one fund, or one type of token.

Everything you paid for the ones you held just before the sale, with dealing fees and stamp duty. If you've sold some before, use what's left of the cost.

Shares, fund units or tokens. Part tokens are fine, for example 0.25.

The sale

Before any fees. For crypto swapped for other crypto, its value in pounds at the time.

Dealing or exchange fees on the sale.

Bought the same back within 30 days?

On the day you sold, or in the 30 days after. If yes, different rules apply first and we'll tell you to talk to us.

The rest of your tax year

Pay, pensions, rent, profits and interest for 2026/27.

Gains on anything else you've sold since 6 April 2026.

Losses on anything else you've sold since 6 April 2026.

Unused losses you've already reported to HMRC.

Your answer

Enter what you paid for your holding, how many you held and sold, what you sold them for, and your income.

About this calculator

For anyone in the UK who sold some or all of a holding of shares, fund units or crypto tokens in the 2026/27 tax year, outside an ISA or pension. Not for NFTs, which aren't pooled, shares from a work scheme, or offshore funds without reporting status, which are taxed differently.

What happens to your answers

We don’t keep them. Your answers go to our server to do the sums and aren’t stored or logged. If you copy a link to your answers, they’re in the link itself, so only share it with people you trust.

How it’s worked out

Shares of one kind in one company, units in one fund, or one type of token form a single pool (a section 104 holding). Its cost is everything you paid for what you still hold, with buying fees. When you sell some, the cost of those is the pool's cost times the number sold, divided by the number held. The pool goes down by the same cost and number. This is the method in HMRC's helpsheet HS284 and Cryptoassets Manual (CRYPTO22200).

The gain is what you sold for, less selling fees and that cost. Losses this tax year come off your gains in full. Losses from earlier years only bring your gains down to the £3,000 tax-free allowance; the rest carries forward. What's left is taxed at 18% inside the basic-rate band your income leaves, and 24% above it.

If you bought the same shares or tokens on the day you sold, or in the 30 days after, those purchases are matched with the sale first, at their own cost, and don't go into the pool (the same-day and 30-day rules). This calculator doesn't work those out: talk to us.

Worked example

You'd pay about £891 Capital Gains Tax on a £7,950 gain.

2026/27 tax year · shares in one company · income £45,000

Worked example, step by step
What you paid for all 4,000 shares you held, with buying costs (the pool)£20,000
Average cost: £5.00 a share, times the 2,000 you sold£10,000
What you sold them for£18,000
Less selling costs (dealing or exchange fees)− £50
Less the cost of what you sold, from the pool− £10,000
Gain on this sale£7,950
Tax-free allowance− £3,000
At 18% (inside the basic-rate band)£4,950
Capital Gains Tax£891
Left in the pool: 2,000 shares, costing£10,000

Worked out using HMRC's published rates for the 2026/27 tax year (6 April 2026 to 5 April 2027), on a yearly basis.

Questions people ask

Do I need to tell HMRC if there's no tax?

If there's tax to pay, yes: on a tax return by 31 January 2028, or sooner with HMRC's real-time Capital Gains Tax service. If you send a tax return, fill in its capital gains pages if everything you sold this year was worth more than £50,000, or your gains before losses were over £3,000, even with no tax. To use a loss later, report it within 4 years.

What about swapping one crypto for another?

Swapping one token for another, spending crypto or giving it away (except to your husband, wife or civil partner) all count as selling it. Use its value in pounds at the time. Moving tokens between wallets you own isn't a sale.

What if I sell and buy back to use my allowance?

Buying back the same shares or tokens within 30 days means the sale is matched with the new purchase, not your pool, so it usually doesn't give the gain you expect. Talk to us before you do it.

More free calculators

Talk to us about your tax.

A free call with the team. We’ll contact you within 24 hours.

Wealth-building, tax-saving tips in your inbox

We'll only use your email to send you our updates.