Guide
Which share purchase cost counts when you sell?
When you bought the same shares more than once, the UK tax cost is not necessarily the purchase you choose in your investment app. Establish the matching first, then calculate the gain.
Quick answer
For ordinary same-class shares in the same company, UK matching generally uses same-day acquisitions first, relevant acquisitions in the following 30 days next, then the pooled holding. A simple purchase-price subtraction can be wrong when those rules apply.
On this page
Why a platform’s selected purchase may not be the tax cost
An app can display investment performance using a presentation method that does not reproduce UK tax matching. For same-class shares in the same company, identify the acquisitions matched to the disposal under the tax rules.
Do not choose the most expensive purchase simply to reduce the gain, or assume that first bought always means first sold. A transfer between providers can also leave acquisition history outside the new platform’s display. Keep records across accounts where the same person owns the relevant taxable holding.
The ordinary matching order
Broadly, match the disposal to relevant acquisitions on the same day first. Then consider relevant acquisitions in the following 30 days. The remaining disposal quantity is matched to the pooled holding, often called the Section 104 holding.
The pool keeps a combined quantity and allowable cost. When a disposal uses part of it, a corresponding proportion of cost is used and the pool’s remaining quantity/cost is reduced. Acquisitions already matched to a sale must not also be added to the pool as if still unmatched.
Residence changes, company reorganisations, employee shares and some funds can require extra steps. Use the detailed rule for the actual asset rather than extending this ordinary example to every security.
Worked example with same-day and 30-day purchases
Assume an ordinary UK-resident individual has 100 pooled shares with £1,000 total cost. They sell 50 shares for £900, with £10 eligible selling costs. They buy 20 same-class shares that day for £320 and 30 more 15 days later for £450. There are no other relevant transactions or adjustments.
| Match | Shares | Allowable acquisition cost |
|---|---|---|
| Same day | 20 | £320 |
| Following 30 days | 30 | £450 |
| Existing pool | 0 | £0 |
The gain is £900 − £10 − £320 − £450 = £120. The original 100-share £1,000 pool remains. Using 50 shares at the old £10 pooled cost would have produced a different and incorrect result for these assumed facts.
A simple pool-only comparison
Suppose instead the pool contains 200 shares costing £2,400 in total, and no same-day or following-30-day purchase matches. Selling 50 uses 50/200 of the pool cost: £600.
At £900 proceeds and £10 eligible sale costs, the gain is £290. The pool left is 150 shares and £1,800 cost. Record both the disposal calculation and the updated pool so the next sale starts from the right figures.
Costs and distributions need careful records
Permitted buying/selling fees and acquisition stamp taxes can affect the allowable cost. Check that they are not already included in the provider’s cost figure. Reinvested ordinary dividends can create new acquisitions while retaining a separate income-tax record.
Fund equalisation, accumulation distributions, excess reportable income, mergers and reorganisations can require further cost adjustments. Employee shares can also involve Income Tax and a special acquisition basis. Keep the tax statements and corporate-action documents; a cash ledger alone may be insufficient.
What to enter into the annual calculator
Prepare one gain or loss for each supported disposal after the matching and relevant adjustments. Then combine those figures with other gains/losses for the tax year. Use the annual allowance once and determine the tax rate from the appropriate income calculation.
Our simple disposal helper does not perform transaction matching. Use its prepared-gains mode after this work has been completed. Keep a reviewable file containing dates, company/class identifiers, quantities, costs, fees, matches, pool movements and the resulting gain or loss.
What to do next
- Use the same company and class of shares, with all relevant dates and quantities.
- Check same-day and following-30-day purchases before using the pool.
- Keep fees, corporate actions and fund adjustments with the cost record.
- Export a complete transaction history around the disposal.
- Reconcile the matched quantities and remaining pool.
- Enter the prepared gain into the annual CGT calculation.
Try the tool
Put the explanation into your own figures
Check the tool’s supported scope, keep the assumptions with the result, and use the official route when you need to report or pay.
About this guide
Written by Dan. Dan has spent 20 years working across payroll, HR, benefits and reward. IsMyPayRight is an independent personal project, not connected with any employer or with HMRC.
AI tools help with research and drafting. The official sources used are listed at the end of the guide.
This is general guidance, not a professional review of your circumstances. Read our editorial process and the corrections log.
Methodology and sources
See how the calculations work, which sources they use, how results are tested, and which payroll details the estimates cannot verify.
Common questions
- Can I choose which share purchase cost to use for UK CGT?
- For ordinary same-class shares in one company, the tax matching generally uses same-day acquisitions, relevant following-30-day acquisitions, then the pooled holding. It is not an unrestricted choice of the most expensive purchase.
- Does the simple CGT helper perform share matching?
- No. Prepare the gain after applicable matching, fees and adjustments first, then use the annual-gains mode. Keep the matches and remaining pool records so later disposals start from the correct cost.
Official sources
Use these references to check the rules behind this guide. Check the tax year and your circumstances before applying an example to your own pay.

