Strategy · lesson 08 of 09

Polymarket historical data: price history and trades for backtesting

Polymarket gives away its price history: two free endpoints return a market’s prices back to its launch, and the Data API returns its trades for three years. What each returns, the limits that trip people up, and where to get bulk on-chain data for backtesting.

Price history from the CLOB

GET https://clob.polymarket.com/prices-history takes market, the outcome token ID, which the Gamma API lists as clobTokenIds; either startTs and endTs, or an interval (1h, 6h, 1d, 1w, 1m, max or all); and fidelity, the “accuracy of the data expressed in minutes”, which defaults to 1 (prices history). It returns pairs of time and price. A batch version takes several markets in one request.

  • Whole-life requests need a coarse fidelity. In our test on the 2024 presidential market, interval=max with fidelity=720 (12 hours) returned 614 points from 5 January 2024; at the default 1-minute fidelity it returned nothing.
  • For fine data, ask in windows: ranges longer than about 15 days are rejected as “too long”, but one-minute points come back for a single day as far back as 2024.
  • Some of the oldest markets, from before 2023, return no history at all.

Price history from the Data API

GET https://data-api.polymarket.com/v2/prices-history?token_id=… does the same with clearer rules (Data API prices history): interval=max “serves the market’s whole life, back to 2022 for the oldest markets, at 12-hour buckets”; “explicit start/end windows cap at 15 days”; and the fine grains are kept for limited periods, “1-minute data at least 7 days, 5-minute at least 60, 30-minute at least 90”. A resolved market ends with a settlement point of 0 or 1.

Trades and closed markets

  • GET data-api.polymarket.com/v2/trades with a market (condition) or event returns a fixed three-year window, up to 1,000 rows a page. For one trader, start=1 “asks for full history” (list trades).
  • GET gamma-api.polymarket.com/markets?closed=true lists resolved markets, with their token IDs, close times and final prices (list markets).
  • Limits are per IP: 1,000 requests per 10 seconds on the CLOB history and 200 on /v2/prices-history (rate limits).

Bulk and on-chain data

Polymarket’s data resources page names third-party sources rather than an official dataset: Goldsky “provides real-time streaming pipelines for Polymarket on-chain activity”, alongside Dune, Allium and CryptoHouse (blockchain data). The Data API’s v1 accounting export was retired on 2 November 2026 with no v2 replacement.

Backtesting with it

  • Mid prices are not fill prices. A backtest that buys at the historical price ignores the spread and fees; see bid vs ask and Polymarket fees.
  • Thin markets move on a few trades, so a strategy that looks profitable on them may not survive real order sizes.
  • Markets that never traded, or were delisted, are missing from many samples. Include resolved losers as well as winners.

Other endpoints, including order books and live data, are in the Polymarket API. To score forecasts against outcomes, use the forecast accuracy calculator.

See it live on Polymarket

Largest on-chain prediction market by volume

Editor score 6.9Restricted
Open Polymarket →

Common questions

Does Polymarket have historical data?

Yes, free. The CLOB prices-history and Data API v2 prices-history endpoints return price history for each outcome token, and /v2/trades returns trades for up to three years. No API key is needed.

How far back does Polymarket price history go?

To 2022 for the oldest markets, at 12-hour intervals, according to Polymarket’s docs. Finer data is kept for shorter periods, at least 7 days for one-minute prices on the Data API, and requests with explicit dates are capped at about 15 days.

Why does Polymarket prices-history return an empty list?

Usually because a whole-life request (interval=max) was made at the default one-minute fidelity. Ask for a coarser fidelity, such as 720 minutes, or request 15-day windows instead.

Can I backtest Polymarket strategies?

You can build a backtest from the free price and trade history, but historical prices are not the prices you would have filled at. Account for the bid-ask spread, taker fees and thin order books.