Skip to the content

Help / Connect your data

Connect OANDA for live forex and CFDs

Live forex, gold and silver, and OANDA’s index, commodity and bond CFDs chart from your own OANDA account. A practice (demo) account is free and enough: no money is needed, and nothing places real orders.

Step by step#

  1. Go to oanda.com and open a free practice account (in many countries OANDA calls it a demo account).
  2. Signed in to OANDA, open My Account › Manage API Access and press Generate. Copy the token.
  3. Open the Account page and find Forex data (OANDA). Paste the token into API token, choose Practice account (or Live account if the token is from a live one) and press Save token.
  4. Wait for Saved: OANDA accepted the token. It shows which OANDA account the token opens.
  5. On the chart, search for a pair (EURUSD, EUR/USD, gold) or a CFD (SPX500, oil, USB10Y). Results marked as your OANDA data are live; CFDs are under the Indices, Commodities and Bonds tabs.

What you get#

  • The pairs, metals and CFDs your OANDA account can trade, live and with history.
  • Prices are OANDA’s mid quotes. A CFD follows its index, commodity or bond but is OANDA’s own contract, so its price differs a little from the index itself.
  • Volume is tick volume (the number of price changes in a bar), as on OANDA’s own charts.

If it doesn’t work#

  • OANDA refused the token: check the account choice matches (a practice token with Practice account). Generating a new token in OANDA stops the old one.
  • A pair is missing: OANDA offers different instruments in different countries; only what your account can trade is listed.
Note:The token is stored encrypted; Remove deletes it.

TradingView and Pine Script are trademarks of TradingView, Inc. OpenTapefolio is not affiliated with or endorsed by TradingView.