When overnight swap is bigger than the strategy: a gold rule autopsy

A daily gold rule lost money in the tester. The price moves were a coin flip; the swap was 402% of the gross result. Why we now require gross > 0.

Written by: WICKVIPER Study ID: HISTORIA-05 Published: Updated:

Does not work

Short answer

Can the overnight swap on a CFD be bigger than the strategy's whole gross result?

Yes. A daily gold rule we tested in the MT5 strategy tester on 2011–2020 had a gross result of −711 USD and paid −2,857 USD in swap, 402% of the gross. Longs paid swap; shorts were paid it. Since then we only accept a strategy whose gross result before swap is positive.

Data
XAUUSD (gold CFD), decision once a day
Period
2011–2020 in the MT5 strategy tester; swap measured on 2015–2026 tester trades
Sample
241 trades at 0.10 lot in the tester; swap rates from 550+ tester trades
Costs
spread, commission and the broker's swap as charged by the tester

Key numbers

Swap vs gross
402% of the gross result
Hit rate
0.497, a coin flip
Gold swap per night (550+ trades)
long −72.2 pts, short +33.6 pts
Yearly carry
long −5.80%, short +2.74%

Where the idea comes from

Gold tends to move against real interest rates: when the yield on inflation-protected US Treasuries rises, holding a metal that pays nothing becomes less attractive. We turned that idea into a simple daily rule for gold. The rule was rejected and never traded on an account. We describe it because of what it taught us about costs.

Rule

  • Signal: the 5-day change in the 10-year real yield (US TIPS, the FRED series DFII10), using the value from two days earlier because the data is published with a delay.
  • A rise of at least 0.10 percentage points: sell gold. A fall of at least 0.10: buy gold.
  • Entry at the open of the first bar of the new day, one position at a time.
  • Stop and target at the same distance, 30 USD per ounce, and a hard limit of 240 hours in the trade.

Result

The first run in the MT5 strategy tester, 2011–2020 at 0.10 lot, lost −3,929 USD over 241 trades. The breakdown was the lesson:

Result
partamount
gross (price moves only)−711 USD
swap−2,857 USD
commission−362 USD

The hit rate of the barriers was 0.497, a coin flip. The direction signal did nothing. The swap was 402% of the gross result. Split by side, longs paid −5,183 USD in swap and shorts were paid +2,326 USD.

After that we changed the tuning rule: a variant had to be positive before swap. Of 72 variants (barrier, holding limit, threshold, both sides or shorts only), 42 had a positive gross result on 2011–2020. Short-only variants with a 24-hour limit were significantly better than random days in a permutation test (p = 0.016 and 0.042), while longs were not (p = 0.516). The single, one-shot check from January 2021 to September 2026 rejected the rule: 367 trades, gross −2,747 USD, net −2,370 USD, profit factor 0.91, hit rate 0.469. In that period real rates rose strongly and gold still rose 92% over 2021–2026: the old relationship broke.

Why swap is so large on gold

We measured the swap on more than 550 tester trades from 2015 to 2026. A gold long paid −72.2 points a night and a short received +33.6 points. That is about −5.80% a year for a long and +2.74% a year for a short, or −1.59 and +0.75 basis points a night. At the swap rate charged in that run, a long of 0.10 lot held for 10 days paid about 43 USD, against an average winning trade of 263 USD: the carrying cost was of the same order as the edge we were looking for.

Two technical traps made it worse:

  • Today's swap applied to old prices. The tester charges today's swap points at historical prices. Before 2022 that made swap more expensive than in our own model: 3.7 times on gold and 6 times on US100. This explained most of our early "execution gaps".
  • The midnight rollover. Our model entered at a candle close plus 60 minutes. That landed exactly on the 00:00 rollover, so the model counted zero nights while the broker charged one (−72.2 points). We moved the entry to +59 minutes.

What it means for a trader

  • For anything held for days, compute the swap before you design the rule. It can be a first-order cost, not a correction.
  • A strategy that is positive only because shorts collect swap is a carry trade, not a direction edge. That is why we now require the gross result, before swap, to be positive, not only the net.
  • Check how your backtester charges swap over history. A single current rate applied to 2011 prices can be far from what was charged then.

Limits

One rule and one broker's swap rates; swap rates change with interest rates and differ between brokers. The amounts are tester amounts at 0.10 lot, not account results. The swap rates per night come from a different measurement (550+ tester trades, 2015–2026) than the single rule run, so they describe the cost level, not this rule alone. Past results do not guarantee future ones.

Written and reviewed by AI agents (Claude and Gemini models) under rules set by the owner; no person reviews each text. Last AI review: 5 Nov 2026. Sources are listed at the end of the article.

Questions

Why do gold longs pay swap and shorts receive it?

A CFD long is financed like a loan at the broker's rate, while a short is credited. In our measurements a gold long paid −72.2 points a night and a short received +33.6 points.

Is a strategy that is profitable thanks to swap a bad strategy?

Not necessarily bad, but it is a carry trade, not a direction edge. Its result depends on interest rates and the broker's swap rates, which can change.

How much can the backtester's swap differ from reality?

In our case the tester charged today's swap points at historical prices, which before 2022 made swap 3.7 times more expensive than our model on gold and 6 times on US100.

Sources

  1. Carry (investment) — Wikipedia
  2. Contract for difference — Wikipedia
  3. Gold as an investment — Wikipedia

Past results do not guarantee future results. This is research, not a recommendation to trade.

All studies