Home / Historical Data / Data API
Free Data API

Free OHLC Preview & Data Quality API

Query historical forex, gold, index, energy and crypto data by symbol, timeframe and date range. JSON or CSV, no key required, with clear rate limits and quality reports.

Updated 2026-11-02 ? 617 datasets ? 22.1M OHLC rows

617datasets available
60/minanonymous rate limit
2kpreview rows per request
31dpreview date range

Need full history? The API is a free preview. Complete CSV, ZIP and Parquet datasets are available as paid downloads. View data pricing.

Base URL

https://www.algospecial.com

No API key required. Requests are rate-limited per IP. Timestamps are broker server time. Some legacy forex exports have no tick volume/spread; those fields return 0.

API guides by market

Use the focused guides for supported symbols, timeframe coverage, request examples and market-specific data notes.

XAUUSD gold API

Gold M1 to MN1 history, 1.8M rows and a 97 A quality score.

Forex API

202 forex-group datasets across majors and crosses.

Crypto API

BTC, ETH, SOL and 30+ altcoin symbols with 24/7 bars.

Indices API

US500, USTEC, US30, UK100, STOXX50, JP225 and AUS200.

Energy API

WTI, Brent and natural gas OHLC history.

Quality API

A-F scores, gaps, duplicates and OHLC integrity checks.

Python guide

Requests, pandas, chunking and 429 retry examples.

CSV and JSON

Field definitions and the best format for your workflow.

Rate limits

Headers, status codes and safe retry behaviour.

OHLC Endpoint

GET /api/ohlc.php

ParameterRequiredDescription
symbolYesExample: XAUUSD, EURUSD, BTCUSDT, USTEC
tfYesM1, M5, M15, M30, H1, H4, D1, W1, MN1
fromYesYYYY-MM-DD
toYesYYYY-MM-DD
formatNojson (default) or csv

Example

curl "https://www.algospecial.com/api/ohlc.php?symbol=XAUUSD&tf=M15&from=2026-01-01&to=2026-01-31&format=json"

Python

import requests

r = requests.get("https://www.algospecial.com/api/ohlc.php", params={
    "symbol": "XAUUSD",
    "tf": "M15",
    "from": "2026-01-01",
    "to": "2026-01-31",
    "format": "json"
}, timeout=30)
data = r.json()["data"]

Data Quality Endpoint

GET /api/data-quality.php

Returns the A–F quality report for a dataset: score, grade, coverage, duplicates, gaps, OHLC violations, outliers, volume/spread checks and issue list.

curl "https://www.algospecial.com/api/data-quality.php?symbol=XAUUSD&tf=M15"

Rate Limits & Errors

Anonymous

60 requests/minute
1,000 requests/day
per IP address

Response headers

X-RateLimit-Limit
X-RateLimit-Remaining
X-RateLimit-Reset

Status codes

200 OK · 400 invalid input · 404 not found · 413 too many rows · 429 rate limited · 500 server error

On 429, wait for the number of seconds in Retry-After. CORS is enabled for browser requests.

Usage & Attribution

The API is free for research, backtesting and commercial applications. Do not resell or redistribute it as a standalone data service. Attribution to AlgoSpecial is appreciated. Data is provided as-is without warranty; verify it against your broker before trading.

API FAQ

Is the OHLC API free?

Yes. The API is free with a per-IP rate limit of 60 requests per minute and 1,000 requests per day.

What formats does the OHLC API return?

JSON by default, or CSV with format=csv. Parquet is available through the download builder, not the API.

How many rows can I request?

The free preview API is limited to 2,000 rows and a maximum date range of 31 days. Full-history datasets are available as paid downloads.

What timezone are timestamps in?

Timestamps are broker server time. Convert to UTC or New York time for session-based strategies.

Related

🚀 Invite friends — Earn $5 You both get $5 credit on Go Ad · opencode.ai AI-Powered Coding Agent — Try Free Build apps, fix bugs & ship faster with opencode. Get $5 free credit when you join. × Ad · quo.com QuoPhone — $20 Visa Gift Card Free Sign up to Quo, subscribe 3 months, get a $20 Visa gift card. Atif's referral gift for you. ×