Real-time orderbook data for every Polymarket market, delivered through a single WebSocket connection.
PolyNode’s Orderbook Stream delivers live orderbook snapshots, depth updates, and price changes for every active Polymarket market. Subscribe to the markets you care about and get enriched, human-readable data pushed to your connection in real time.
108,000+ markets
Every active Polymarket market is tracked. Subscribe to specific markets or get everything at once.
Enriched data
Snapshots include the event title, market question, outcome label, slug, and condition ID. Streaming updates include the slug and outcome for lightweight routing.
250ms batching
Updates are batched into 250ms windows for efficient delivery. One message per tick with all changes for your subscribed markets.
Compression included
Add &compress=zlib to your connection URL for ~50% bandwidth savings. Recommended for production.
Subscribe using a condition ID or token ID from the REST API. Both sides of the market (Yes + No) are included automatically.
Copy
const ws = new WebSocket("wss://ob.polynode.dev/ws?key=pn_live_YOUR_KEY");ws.onopen = () => { // Subscribe by condition ID — resolves to both Yes + No tokens ws.send(JSON.stringify({ action: "subscribe", markets: ["0x7cb525e831729325d651017f81cbcb6f1adde5011c7b2283babea00b4ae93ae7"] }));};ws.onmessage = (event) => { const msg = JSON.parse(event.data); if (msg.type === "snapshot_batch") { for (const snap of msg.snapshots) { console.log(`${snap.question} [${snap.outcome}]: ${snap.bids.length} bids, ${snap.asks.length} asks`); } } else if (msg.type === "batch") { for (const update of msg.updates) { if (update.type === "price_change") { for (const asset of update.assets) { console.log(`${update.slug} [${asset.outcome}]: ${asset.price}`); } } } }};
Use the REST API to find condition IDs: curl -s -H "x-api-key: pn_live_YOUR_KEY" "https://api.polynode.dev/v1/search?q=bitcoin" — each result includes the condition_id you can pass directly to the orderbook subscribe.
3
Receive data
You’ll immediately receive an orderbook snapshot for each subscribed token, then live batched updates:
You can identify markets using any of these formats:
Firehose (all markets)
Slug (recommended)
Condition ID
Token ID
Subscribe to every active market with a single message. Pass "*" as the market identifier to get the full firehose of all 100,000+ tokens.
Copy
{ "action": "subscribe", "markets": ["*"]}
The server responds with "firehose": true and the total number of active tokens. Live updates start flowing immediately while snapshots stream in the background.
The simplest way to subscribe to specific markets. Use the slug from the Polymarket event URL. The server resolves it to all token IDs for that event (typically 2 per market, one for each outcome).
Use the PolyNode REST API to search for markets and find their slugs, condition IDs, or token IDs:
Copy
# Search by keywordcurl -s "https://api.polynode.dev/v1/search?q=bitcoin" | python3 -m json.tool# Look up by slugcurl -s "https://api.polynode.dev/v1/markets/slug/what-price-will-bitcoin-hit-in-march-2026"# Look up by condition IDcurl -s "https://api.polynode.dev/v1/markets/condition/0x561ffbf7de21ef3781c441f30536b026d2b301d7a4a0145a8f526f98db049ba2"
Or just grab the slug from any Polymarket event URL: polymarket.com/event/{slug}.
All paid tiers can subscribe to every active market with no token limit. Access is gated by the number of simultaneous WebSocket connections you can open to the Orderbook Stream.
Tier
Connections
Market subscriptions
Session limit
Free
1
Unlimited
1 hour/day
Starter ($50/mo)
2
Unlimited
Unlimited
Growth ($200/mo)
10
Unlimited
Unlimited
Enterprise ($750/mo)
Unlimited
Unlimited
Unlimited
Each Polymarket market has two tokens (one per outcome). Subscribing to both tokens of a market gives you the full two-sided orderbook.
Free tier includes the full firehose. Subscribe to every market and see the full data flow. The only limit is a 1-hour daily session so you can properly evaluate the product before upgrading.
Orderbook connections are separate from main WebSocket connections. Your plan’s WebSocket and firehose limits (shown on the rate limits page) apply to the main feed at ws.polynode.dev. The limits above apply only to the Orderbook Stream at ob.polynode.dev. Session time resets at midnight UTC.
Live updates start flowing immediately. You don’t have to wait for snapshots to finish. Snapshots are delivered in batches of 50 every 200ms for tokens that have active book data.