The 30-day rule - often called the "bed and breakfast" rule - is codified in TCGA 1992 s.106A and detailed in HMRC's Capital Gains Manual at CG51565. It is the second of HMRC's three share matching rules for capital gains tax, and prevents investors from selling shares to realise a gain or loss and then immediately rebuying the same shares to reset their cost basis. Understanding this rule is essential for anyone planning to sell and repurchase investments.
What is "bed and breakfasting"?
The term "bed and breakfast" dates back to a common tax planning strategy used before 1998. Investors would sell shares at the end of one day ("put them to bed") and buy them back the following morning ("breakfast"). This allowed them to:
- Crystallise a capital gain to use up their annual exempt amount.
- Crystallise a capital loss to offset against other gains.
- Reset the cost basis of their shares to the current market value.
In 1998, the government introduced TCGA 1992 s.106A to close this loophole. The original overnight bed and breakfast transaction is now caught by the same-day rule (if repurchased on the same day) or the 30-day rule (if repurchased within 30 days).
How the 30-day rule works
Under the rules set out in HMRC Helpsheet HS284, if you sell shares and buy shares of the same class in the same company within 30 calendar days of the sale, the sold shares are matched against the repurchased shares for CGT purposes. This means:
- The cost basis for the matched shares is the price you paid when you rebought them, not the Section 104 pool cost.
- The repurchased shares do not enter (or re-enter) the Section 104 pool - they have been consumed by the matching.
30-day window counting
The 30-day period starts on the day after the disposal. So if you sell on 1 March, the 30-day window runs from 2 March to 31 March inclusive. A repurchase on 31 March is caught; a repurchase on 1 April is not.
Priority order
The 30-day rule sits second in the matching priority, after the same-day rule but before the Section 104 pool:
- Same-day rule - match against same-day purchases.
- 30-day rule - match against purchases in the following 30 days.
- Section 104 pool - match against the average-cost pool.
Worked example - full matching
Claire holds 1,000 shares in GlobalCo plc through her Section 104 pool at an average cost of £5.00 per share (total cost: £5,000). On 1 March 2025, she sells all 1,000 shares at £4.00 each, intending to realise a loss. On 15 March 2025 - 14 days later - she buys 1,000 shares in GlobalCo at £4.20 each.
Because the repurchase falls within 30 days of the sale, the 30-day rule applies. All 1,000 sold shares are matched against the 1,000 repurchased shares.
- Proceeds: 1,000 x £4.00 = £4,000
- Cost (from repurchase): 1,000 x £4.20 = £4,200
- Loss: £4,000 - £4,200 = -£200
Impact on the allowable loss
Without the 30-day rule, the shares would have been matched against the Section 104 pool at £5.00 each, producing a loss of £1,000. The rule significantly reduces Claire's allowable loss because it uses the repurchase price of £4.20 rather than the original pool cost of £5.00.
Worked example - partial matching
Using the same scenario, suppose Claire only rebuys 600 shares on 15 March at £4.20 each, rather than the full 1,000. The 30-day rule matches 600 of the 1,000 sold shares against the repurchase. The remaining 400 fall to the Section 104 pool.
30-day matched portion (600 shares):
- Proceeds: 600 x £4.00 = £2,400
- Cost: 600 x £4.20 = £2,520
- Loss: £2,400 - £2,520 = -£120
Section 104 pool portion (400 shares):
- Proceeds: 400 x £4.00 = £1,600
- Cost from pool: 400 x £5.00 = £2,000
- Loss: £1,600 - £2,000 = -£400
Claire's total loss is -£120 + -£400 = -£520. This is less than the £1,000 loss she would have realised without any repurchase.
Effect on the Section 104 pool
Shares consumed by the 30-day rule do not enter the Section 104 pool. In Claire's partial matching example:
- Before the sale: 1,000 shares in the pool at £5,000 total cost.
- 400 shares are sold from the pool (for the portion not caught by the 30-day rule).
- After the sale: 600 shares remain in the pool at £3,000 total cost.
- The 600 repurchased shares were fully consumed by the 30-day matching - they do not re-enter the pool.
- Claire is left with 600 shares in her Section 104 pool at a cost of £5.00 each.
If Claire had repurchased only 400 shares instead of 600, the remaining 200 shares (repurchased but not needed for 30-day matching) would be added to the Section 104 pool.
Multiple repurchases within 30 days
If you make multiple purchases within the 30-day window, they are matched in chronological order - the earliest purchase within the window is matched first. This is different from the same-day rule, where all purchases on the day are pooled together. For the 30-day rule, the order of repurchase dates matters.
Waiting 31 days - legitimate planning
The simplest way to avoid the 30-day rule is to wait at least 31 days before repurchasing the same shares. If you sell on 1 March and rebuy on 1 April (31 days later), the 30-day rule does not apply. Your sale is matched against the Section 104 pool, and the repurchase starts a new addition to the pool at the new cost basis.
The risk with this approach is that the share price may move against you during the waiting period. You are exposed to market movements for over a month.
Spouse and civil partner transfers
Transfers between spouses and civil partners are not disposals for CGT purposes - they happen at no gain, no loss. This means one partner could sell shares to realise a loss, and the other partner could buy the same shares within 30 days without triggering the bed and breakfast rule, because they are different taxpayers. The repurchase by a spouse is not caught by the 30-day rule because it is a different person acquiring the shares.
However, this must be a genuine arrangement. HMRC may challenge transactions that appear to be artificial tax avoidance schemes, particularly if the shares are immediately transferred back.
ISA and pension repurchases
Common pitfall
If you sell shares in a general investment account and repurchase the same shares within an ISA or pension wrapper within 30 days, the 30-day rule still applies. The matching is based on shares of the same class in the same company, regardless of the account type. Buying within an ISA does not exempt you from this rule.
Key points to remember
- The 30-day window starts the day after the sale, not on the day of the sale itself.
- The rule applies to shares of the same class in the same company only.
- Partial repurchases result in partial matching - only the number of shares repurchased is matched.
- Multiple repurchases within 30 days are matched chronologically (earliest first).
- Shares matched under the 30-day rule do not enter the Section 104 pool.
- Buying within an ISA or pension still triggers the rule.
- Waiting 31 or more days avoids the rule entirely.
- A spouse or civil partner buying the same shares is not caught by this rule.
How FiscalFox applies the 30-day rule
FiscalFox automatically identifies repurchases within the 30-day window and applies the bed and breakfast matching rule. Each disposal computation clearly shows whether shares were matched under the same-day rule, 30-day rule, or Section 104 pool. This ensures your calculations are HMRC-compliant and provides a clear audit trail for your SA108 filing.