BLACK FRIDAY 30% OFF
BLACK FRIDAY SALE 30% OFF MASTERCLASSES USE CODE BLACKFRIDAY SALE STARTS IN 03d 10h 35m 08s
Skip to main content

The UK 30-Day Share Matching Rule Explained With Examples

UK Capital Gains Tax share identification generally matches disposals first against acquisitions on the same day, then against eligible acquisitions made in the following 30 days, and only then against shares in the Section 104 holding. This prevents an investor from freely choosing which historical shares are treated as sold for tax purposes. Matching applies to securities of the same class in the same company held in the same capacity, subject to detailed rules and exceptions.

HMRC’s November 2026 updates to CG51555 and HS284 provide the authoritative sequence. The share identification rule is distinct from the trading platform’s display of an average purchase price and should be calculated before finalising any GIA capital gain.

Thirty-day UK share matching: 60-share sale
  1. 1 / 4

    Sell 60 shares at £20: £1,200 proceeds

  2. 2 / 4

    Buy 20 of the same class within 30 days at £18: £360 matched cost

  3. 3 / 4

    Other 40 matched to £10 Section 104 pool: £400 cost

  4. 4 / 4

    Gain: £1,200 − £760 = £440 before fees

This hypothetical example assumes eligible matching conditions. Same-day acquisitions take priority over the subsequent 30-day rule.

The share identification hierarchy

For relevant disposals, the order is: 1. shares acquired on the disposal date; 2. shares acquired in the subsequent 30 days where the statutory residence conditions are met; 3. the existing Section 104 pool of relevant shares; and 4. specific later acquisitions if earlier rules cannot exhaust the disposal. Same-day and 30-day matched purchases do not enter the ordinary Section 104 pool for those matched quantities.

Matching depends on the legal owner, capacity, share class and acquisition dates. Shares in a tax-exempt ISA are not mechanically interchangeable with taxable shares for this analysis.

What is a Section 104 share pool?

For most individuals’ taxable holdings, repeated acquisitions of the same class of shares in the same company in the same capacity contribute quantity and allowable expenditure to a Section 104 pool, unless identified under the priority matching rules. The pooled average cost per share changes when new eligible acquisitions enter the pool. Disposals matched against the pool reduce its share count and allowable cost proportionately.

Suppose 100 shares cost £1,000 and another 100 cost £1,400. The pool holds 200 shares with allowable cost £2,400, or £12 per share before other acquisition charges.

Worked example: the 30-day rule overrides the pool

An investor already owns 100 shares with a pooled allowable cost of £10 each. They sell 60 shares at £20 each for £1,200, excluding fees, and buy 20 shares at £18 ten days after the sale. The first 20 shares sold match the new 20 bought at £18, costing £360. The other 40 sold match the existing Section 104 pool at £10 each, costing £400. Total allowable matched cost is £760, so the gross capital gain is £1,200 − £760 = £440.

Without the 30-day repurchase, all 60 would have matched the £10 pool in this simplified situation, producing a £600 gain. The difference arises from identification, not from changing the real sale proceeds.

Same-day, 30-day and Section 104 compared

OrderAcquisition matchedKey consequence
1Same calendar dayPriority over other historic purchases
2Following 30 days, when eligibleCan change cost from old pool value
3Section 104 holdingUses pooled average cost for remaining quantity

How same-day share purchases work

If the investor buys 50 qualifying shares in the morning and sells 40 of the same class that day in a taxable account, the 40 disposed of are generally identified against same-day acquisitions before older pool holdings. Where several purchases occur that day, the statutory rules can treat relevant acquisitions as a same-day aggregate, rather than letting the investor select a preferred lot.

The order in which the broker displays purchase entries may not reflect HMRC’s identification method. Retain timestamps and full cost records but calculate tax using the legal matching framework.

Why it is called the bed-and-breakfast rule

Historically, investors could sell shares to crystallise a loss and rebuy them very shortly afterwards while retaining similar economic exposure. The 30-day rule restricts the tax effect of certain rapid taxable same-company repurchases by matching them against the disposal. It does not prohibit selling or purchasing securities and is not a 30-day lock-up on trading.

Its impact can be to increase or decrease the particular gain or loss compared with a calculation using only the old pool; the result depends on prices and allowable costs.

What if a different share class or issuer is purchased?

Share matching requires attention to securities of the same class in the same company and capacity. A different company’s shares normally do not enter the original company’s matching pool simply because they operate in the same sector. However, economically similar securities or reorganisations may have their own rules, so avoid assuming every superficially different ticker automatically defeats relevant legal provisions.

Corporate actions, mergers, rights issues and offshore fund interests can require separate HMRC treatment beyond an ordinary listed equity example.

Does the rule apply to Bed and ISA?

A purchase inside an ISA is generally a tax-exempt acquisition, rather than an ordinary taxable acquisition for the GIA 30-day matching process. A Bed and ISA sale from a taxable account nevertheless creates a CGT disposal that must be calculated, and other taxable acquisitions around that sale can still be relevant. The ISA subscription and repurchase are separate transactions subject to eligibility and fees.

See Bed and ISA explained and HMRC’s share identification guidance for the distinction.

Fees and foreign currency affect the cost basis

Allowable acquisition expenditure can include relevant purchase costs, while selling costs can reduce disposal proceeds, subject to tax rules. For overseas shares, GBP acquisition and disposal values generally need appropriate exchange-rate conversions at relevant transaction dates; calculating the gain only in USD can be misleading for a UK resident.

Reinvested dividends can buy new shares and become additional taxable acquisitions. A broker’s simplified gain display may not properly incorporate all these effects or the 30-day rule.

Recordkeeping and claim checklist

  1. List the company and exact share class for every trade.
  2. Record sale quantity, proceeds, currency, charges and date.
  3. Identify all eligible same-day acquisitions.
  4. Search for relevant acquisitions in the 30 days after the sale.
  5. Match remaining disposal quantity against the Section 104 pool.
  6. Adjust pooled quantity and allowable expenditure correctly.
  7. Reconcile dividends, rights issues and previous corporate actions.
  8. Use HMRC HS284 or professional advice for complex cases.

Frequently asked questions

Does the UK 30-day rule stop me buying shares?

No. It changes CGT share identification for certain taxable repurchases, not permission to trade.

Does it apply to the shares I buy after selling?

Relevant same-company, same-class purchases within the 30-day window can be matched to the prior sale under HMRC rules.

Is the rule the same as the Section 104 pool?

No. Same-day and eligible 30-day matches have priority before the pooled holdings.

Can I choose my highest-cost shares to sell for UK CGT?

Generally not; statutory matching rules govern relevant disposals.

Does an ISA purchase cause the same taxable matching?

Eligible ISA purchases are generally outside ordinary taxable same-capacity acquisition matching.

Related Traders MBA education

Primary sources

General education only: Not personalised financial, tax or legal advice. Dates and rules refer to the information available when checked and may subsequently change.


Stay Ahead of the Markets

Get market analysis, financial news and practical trading insights delivered straight to your inbox.