Before you start
- An email address (or a Google/GitHub login)
Create your Massive (Polygon.io) API key
- 1
Create an account
Go to massive.com (polygon.io redirects there) and click Sign up. Confirm your email.
- 2
Open API Keys in the dashboard
In the dashboard choose Keys (or API Keys) in the left menu. A Default key already exists.
- 3
Copy or create a key
Click the copy icon next to the default key, or New Key to create a separate one per project so you can revoke it independently.
- 4
Pick a plan if you need more
The free plan works immediately. Upgrade under Billing for real-time data, minute bars or no rate limit; the same key gains access.
Test the key
Before wiring the key into a strategy, make one request by hand. It separates “the key is wrong” from “my code is wrong”.
curl -s "https://api.massive.com/v2/aggs/ticker/AAPL/prev?adjusted=true&apiKey=$POLYGON_API_KEY""status":"OK" with a results bar means the key works. 401/403 means an invalid key or data your plan does not include.Add the key to your AlgoGP project
- 1
Open your project’s APIs & keys tab
Open the strategy project, select APIs & keys, and under Platforms choose Massive (Polygon.io) (Pro).
- 2
Paste each value
Paste the values into
POLYGON_API_KEYand click Save. Values are encrypted at rest, never shown again and never written into code or exports. - 3
Run locally with the same names
Exported projects read the same names from
.env(copy.env.example). Keep.envout of version control.
POLYGON_API_KEY=paste-your-value-hereTroubleshooting
429 Too Many Requests- Over 5 calls per minute on the free plan. Wait and fetch larger ranges per call.
NOT_AUTHORIZED- The data (e.g. minute bars, real-time, options) is not in your plan.
- Empty
results - A wrong ticker prefix (
X:crypto,C:forex) or a range outside your plan’s history.
Frequently asked questions
Can I have more than one Massive API key?
Yes. Create one per app in the dashboard and revoke them individually.
Should I send the key in the URL or a header?
Both work. A header (Authorization: Bearer) keeps it out of logs; the query parameter is easier for quick tests.
Turn Massive (Polygon.io) data into a tested strategy
Backtest an idea in the browser, then export Python whose live loop reads candles straight from Massive (Polygon.io) with your own key.
- Generated Massive (Polygon.io) candle fetcher, closed bars only
- An AI copilot that writes and revises the rules
- Pair it with Alpaca, Binance, OANDA or another broker
Free plan, no card required. Massive (Polygon.io) is included with Pro.
How the Massive (Polygon.io) API works
AlgoGP is not affiliated with Massive (Polygon.io). Menus get renamed from time to time; if a label differs, the official documentation has the current path.