forexthrive backtesting calculation of Overnight Swap/Rollover

SWAP calculation

There is no generic way to calculate the SWAP, since swaps are tradable derivative, but there is a way to calculate approximate values. It's also worth mentioning that each and every market and financial instrument follow different rules therefore forex trading has many forms.

Most brokers use the Tom/Next (Tomorrow/Next) adjustment to roll open positions over to the next trading day. The main component forming the Tom/Next is the interest rates differential between the currencies And this is how swap is calculated for the back-testing games, so values are approximate.

For instance, if one currency has an interest rate of 5% and the other has a rate of 3%, it has a 2% IRD. If you were to buy the currency that pays 5% against one that pays 2%, you would be paid on the difference with daily interest payments (2%/365 days) and there it is the IRD per day for rolling over a open trade to the next day.

Brokers apply the swap rate by directly changing the AVG position open price. If you see swap in your trade reports , then this values are most likely indicative and in reality the rollover happen in the form of pips/ticks by directly changing the open price of the trade.

Swaps are one of the most complex financial derivatives

Simplified info list:

  1. A swap or rollover is the interest earned or paid for a position kept open overnight.
  2. A rollover/swap is often calculated as pips or a ticks (min price move of contract).
  3. Check your broker Overnight Policies because the swap will vary from broker to broker.
  4. Wednesday credit/debit charge carries at a triple rate. It might be the Thursday or Friday check broker's policy.
  5. Additional fees may be added if applicable by the broker. (admin fee, financing cost )

Interesting readings:

BIS (Bank for International Settlements) by members of the Monetary and Economic Department


IMF (International Monetary Fund) FX Swaps: Implications for Financial and Economic Stability Prepared by Bergljot B. Barkbu and Li Lian Ong