XAUUSD M30 Historical Data CSV
Preview the XAUUSDm M30 OHLC data, then buy the full 100,000-row CSV for gold EA backtesting, Python research, data-quality testing and strategy validation. The page also explains the exact columns and the checks you should run before trusting any backtest.
100,000 OHLC candles plus header.
M30, useful for swing, intraday and gold EA testing.
XAUUSDm broker suffix. Rename/mapping may be needed for other brokers.
MT5 testing, Python backtests, feature engineering and ML experiments.
CSV Columns Explained
| Column | Meaning | Backtesting Note |
|---|---|---|
| Timestamp | Broker candle open time. | Use it as the index in Python and verify timezone before comparing another broker. |
| Open, High, Low, Close | Gold candle prices. | Validate that High is not below Open/Close and Low is not above Open/Close. |
| TickVolume | Number of broker ticks inside the candle. | Tick volume is broker-feed activity, not centralized exchange volume. |
| Spread | Recorded broker spread value. | Do not ignore spread when testing scalpers or pending orders. |
How to Use This XAUUSD CSV Correctly
- Buy the full CSV and run it through the XAUUSD CSV Data Quality Checker.
- Check missing candles, duplicate timestamps, abnormal jumps, bad OHLC rows and spread behavior.
- Normalize symbol naming if your broker uses XAUUSD, XAUUSDm, XAUUSD.pro or another suffix.
- For Python, sort candles ascending by timestamp before calculating indicators.
- For MT5 testing, include spread, slippage, commission and broker stop-level assumptions.
Python Backtesting Starter
This starter keeps the logic simple: load the file, parse time, sort history and create a basic candle range feature. It is intentionally not a trading recommendation.
import pandas as pd
df = pd.read_csv("XAUUSDm_PERIOD_M30_OHLC.csv")
df["Timestamp"] = pd.to_datetime(df["Timestamp"])
df = df.sort_values("Timestamp").set_index("Timestamp")
df["range"] = df["High"] - df["Low"]
df["body"] = (df["Close"] - df["Open"]).abs()
df["direction"] = (df["Close"] > df["Open"]).astype(int)
print(df.tail())
print(df[["range", "body", "TickVolume", "Spread"]].describe())
What This Dataset Can and Cannot Prove
Researching gold volatility, M30 swing behavior, rough EA logic, feature engineering and CSV import testing.
Claiming live profitability without tick data, bid/ask execution, slippage, news risk and broker-specific testing.
Use the EA Backtest Reality Checker before trusting any curve.
Need M1, tick-level, broker-specific exports or an EA built around this? Request a custom data or EA quote.
Free Data Tools for XAUUSD
Validate, preview and compare the data before you download.
Go Beyond the Raw CSV
Build a custom date range, add technical indicators, or download a machine-learning dataset with triple-barrier labels and chronological splits.
Choose the next useful step
Most visitors arrive with one question: build, test, price, or trust. These shortcuts keep the path practical.
Go deeper before you build, download or automate
Hand-picked engineering articles, indicator breakdowns and trading-system tools so visitors keep exploring instead of leaving after one page.
Pine Script to MT4/MT5 Conversion Planner
Analyze Pine strategies, repainting risk, TradingView alert bridges, MTF synchronization and the correct MQL4/MQL5 build path before paying for conversion.
Open planner
3-in-1 MT5 Indicator Bundle
12H Bias Engine, Smart Money Institutional Flow Dashboard and D1/H1 pending-signal logic with MQ5 + EX5 source included via Etsy.
MT5 Bank Orders Institutional Flow Dashboard
Supply/demand zones, BOS/CHoCH, liquidity levels, FVG, equal highs/lows and confirmed trade-plan logic explained with EX5 download.
MT5 Asia London NY Liquidity Engine
Asia range, London raid and New York continuation/reversal planning with internal session backtest stats and entry/SL/TP dashboard.
Interactive Brokers RSI Pair Trader
Tkinter desktop trading workflow, TWS API connection handling, RSI pair logic, risk controls and custom IBKR development positioning.