Polymarket Bot Tutorial · Chapter 21 of 32
Polymarket binary Yes/No market bot strategies: standard event contracts, hard-capped 1x leverage, scale via portfolio breadth, common mistakes (chasing 0.99), and code skeleton.
What this chapter covers
Binary (Yes/No) markets are Polymarket's foundation. Most strategies live here. This chapter covers the leverage cap, the 0.99-price trap that catches new builders, and the breadth-not-size pattern that production bots converge on.
- What binary markets cover
- The 1x leverage cap (and how to scale around it)
- Common mistake: chasing 0.99 prices
- Portfolio breadth as effective leverage
- Risk per market vs portfolio
- Code: scan binary markets and place sized buys
What binary markets cover
Binary markets are the foundation of Polymarket: a single yes/no question with two outcome tokens. "Will Trump win the 2024 election?" is binary; "Who will win the 2024 election?" with 5 candidates is NegRisk (chapter 11).
The two outcome tokens (YES and NO) on a binary market sum to 1.0 minus a small spread tax. You can buy either side; both sides have their own order book. The pricing is symmetric - buying YES at 0.40 is equivalent to selling NO at 0.60 in expected payoff.
Most non-tournament markets on Polymarket are binary: weather questions, single-event political outcomes, individual sports games, single price-target crypto questions. The bot pattern is similar across most of them.
The 1x leverage cap (and how to scale around it)
Polymarket binaries are 1x leverage: you spend $40 to buy 100 shares at 0.40; max payout is $100. There is no margin and no liquidation. The capital efficiency is lower than perp futures (chapter 24) where 2-25x is available.
Scaling around the 1x cap means either: (1) deploying more capital across markets - diversify rather than lever, (2) cycling capital through resolving markets - capital frees up on each resolution and rotates to the next, (3) using NegRisk markets where the sum-to-1 arb can produce effective synthetic leverage.
The right framing for binary strategy: low-leverage, high-breadth. 50 small positions across 50 markets is the typical mature bot profile, not 5 big positions on 5 markets.
Common mistake: chasing 0.99 prices
The most common binary-bot failure: buying a near-resolution heavy favorite at 0.99, expecting easy 1c payout when it resolves YES.
The math: at 0.99, you pay 99c to win 1c. A 1% failure rate (1 in 100 markets), each costing you 99c, wipes out 99 successful 1c wins. The risk-reward ratio is brutal at the extreme.
Capacity is also a problem. The book at 0.99 is thin; placing meaningful size walks the price up to 0.995 or higher, eroding the already-thin edge.
Stay out of markets priced > 0.92 unless you have a specific strategy designed for the tail-yield arb profile. Most binary bots should never buy above 0.85.
Portfolio breadth as effective leverage
You cannot leverage individual positions but you can leverage the portfolio's variance characteristics by holding many uncorrelated bets simultaneously.
50 positions at $20 each is $1,000 in play. If win rate is 55% on +3c/-4c economics, expected daily PnL is (0.55 × 3 − 0.45 × 4) × 50 × $0.20 = $1.50 expected, with bounded variance. Same expected return, much lower drawdown, vs a single $1,000 position.
Constraint: positions must be genuinely uncorrelated. 50 NFL favorites in a single weekend are not 50 independent bets; they are largely one weather-and-favorite bet correlated across games. Diversify across sport, event type, time horizon.
Risk per market vs portfolio
Two risk caps, both required.
- Per-market: max $X per market regardless of edge. Caps catastrophic single-market loss. Common value: $25-100 per market.
- Portfolio: max total capital deployed at any time. Caps total drawdown across uncorrelated bad days. Common value: 50-70% of wallet balance.
The per-market cap is the more important one because it bounds the blast radius of any single bug or edge-disappears event. The portfolio cap is a sanity check; with 50+ positions, the law of large numbers usually keeps you within bounds even without it.
Both caps should be enforced in code, not in head. A bot without enforced caps will eventually find the configuration where it deploys 90% of capital into a single market and lose it.
Code: scan binary markets and place sized buys
Reference: scan top-volume binary markets, filter for valid setups, place sized FOK buys.
def scan_and_buy():
events = gamma_top_events(limit=50, active=True, closed=False)
for ev in events:
for m in ev.get("markets", []):
if m.get("negRisk"): continue # binaries only
outs = json.loads(m["outcomes"])
prices = [float(p) for p in json.loads(m["outcomePrices"])]
for i, out_name in enumerate(outs):
if not setup_qualifies(m, i, prices[i]): continue
tok = json.loads(m["clobTokenIds"])[i]
size = compute_size(m, prices[i])
if size < 5: continue
place_fok(tok, "BUY", prices[i] + 0.02, size, neg_risk=False)
def setup_qualifies(m, idx, price):
return 0.10 <= price <= 0.85 # avoid extremes
The setup_qualifies function is where your strategy lives. The wrapper is just plumbing.





