Guide
Market dataOptionsStocksIndices API key

ThetaData API guide

Options backtests need option prices, not just the underlying. ThetaData is one of the most affordable sources of full options history.

Last verified · Also known as ThetaData API, Theta Terminal

Quick answer

ThetaData sells US options and stock market data, including full OPRA tick history, quotes, OHLC, open interest and greeks. You run the Theta Terminal (a Java app) logged in with your account, and query it over a local HTTP API (by default on port 25510) or with the Python library. A free tier gives end-of-day data.

ThetaData API at a glance

Pricing
Free EOD tier; monthly plans for history and real time
Availability
Worldwide
Paper trading
Not applicable (data only)
Integration type
Local gateway
In AlgoGP
Design and backtest in AlgoGP, connect the exported code
Access
Local Theta Terminal + HTTP API
Data
Options ticks, quotes, OHLC, OI, greeks; stocks; indices
Free tier
End-of-day

Build a ThetaData strategy with AlgoGP

AlgoGP does not connect to ThetaData natively yet. ThetaData connects through a local gateway, socket, FIX or Protobuf stack rather than plain HTTPS, so it runs as a separate process next to your strategy.

  1. 1

    Design and backtest in AlgoGP

    Describe the strategy to the copilot and backtest it on years of normalized history. The result does not depend on any vendor.

  2. 2

    Export the Python project

    Every project exports strategy.py, market_data.py, brokers.py and live.py. The strategy only sees bars, cash, positions and orders, never a vendor’s wire format.

  3. 3

    Plug in ThetaData

    Implement the four adapter methods (account, positions, submit_market_order and a candle fetcher) with ThetaData’s SDK, or keep a built-in platform for paper trading and add ThetaData when you go live.

Built-in data sources for the same markets: Alpaca, Yahoo Finance, Alpha Vantage, OANDA.

ThetaData API: frequently asked questions

Why does ThetaData need a terminal?

The terminal streams compressed data from ThetaData’s servers and serves it locally, which keeps large requests fast.

Design and backtest your ThetaData strategy first

AlgoGP turns an idea into Python and tests it on years of history before you connect it to ThetaData. The exported code keeps the broker behind four small adapter methods.

  • AI copilot writes and revises the rules
  • Backtests with realistic costs
  • Exported Python ready to wire to ThetaData

Free plan, no card required.

ThetaData alternatives

Frameworks that connect to ThetaData

Independent guide. AlgoGP is not affiliated with ThetaData. Limits, prices and availability change; confirm them in the official documentation. Nothing here is investment advice.

Build a strategy