The Polymarket sports trading bot is one open source Python file. It prints every game where Polymarket’s price is 5 points or more away from the sportsbook fair price, and with --trade it buys the cheap side from your own Polymarket account.
Get the bot and a key
You need Python 3.9 or newer and a dino.markets API key. The Free plan has 1,000 credits a month and needs no card. Get a key, then:
git clone https://github.com/dino-markets/polymarket-sports-trading-bot cd polymarket-sports-trading-bot export DINO_API_KEY=your-api-key
Run it and read the table
Name the leagues to read and the smallest gap to print. This run read the NFL and printed gaps of 4 points or more.
python3 bot.py --league nfl --min-gap 4
The first five rows on 3 Dec 2026 at 00:45 UTC:
Game Starts (UTC) Side Polymarket Fair Gap Books Denver Broncos at New York Jets 2026-12-13 18:00 Denver Broncos 0.660 0.600 -6.0 46 Indianapolis Colts at Philadelphia Eagles 2026-12-13 18:00 Philadelphia Eagles 0.680 0.625 -5.5 46 Green Bay Packers at New Orleans Saints 2026-12-06 18:00 Green Bay Packers 0.740 0.688 -5.2 57 Houston Texans at Washington Commanders 2026-12-13 18:00 Washington Commanders 0.500 0.451 -4.9 46 Atlanta Falcons at Cleveland Browns 2026-12-13 18:00 Cleveland Browns 0.570 0.524 -4.7 46
Polymarket is the price of one share that pays $1 if that side wins. Fair is what the sportsbooks say that side is worth. Gap is Fair minus Polymarket, in points of probability, so a positive gap means Polymarket is cheaper than the sportsbooks and a negative gap means it is dearer. Books is the number of sportsbooks behind the fair price.
How the fair price is built
A sportsbook’s prices for the two sides of a game add up to more than 100%. The extra is the book’s margin. The bot removes it in three steps:
- Turn each decimal price into a probability, 1 divided by the price.
- Divide each probability by the book’s total, so the book adds up to exactly 100%.
- Take the median across all sportsbooks for each side.
Only sportsbooks count. Prediction markets and betting exchanges are left out. Implied probability and the vig explains the margin.
See where the prices come from
The bot makes one request for each league. The answer holds every sportsbook and Polymarket for the same game, so nothing has to be matched by team name.
curl "https://api.dino.markets/v2/odds?league=nfl&markets=moneyline&books=polymarket&limit=1" \ -H "Authorization: Bearer $DINO_API_KEY"
The Polymarket part of the answer on 3 Dec 2026:
{
"key": "polymarket",
"name": "Polymarket",
"markets": [
{
"key": "moneyline",
"period": "game",
"line": null,
"main": true,
"updated_at": "2026-12-03T00:35:02Z",
"outcomes": [
{
"name": "Los Angeles Rams",
"participant_id": "p_jxucgly",
"side": "home",
"price": "2.128",
"american": "+113",
"market_id": "45077088642640837041009614766924082417445760496037223554921608627081843953099"
},
{
"name": "Kansas City Chiefs",
"participant_id": "p_jmdgybh",
"side": "away",
"price": "1.852",
"american": "-117",
"market_id": "41759905716400606647078786966427979896667548153125754792608858623622998428446"
}
]
}
]
}price is decimal odds, so the Rams at 2.128 are a share price of 1 / 2.128, or 47 cents. market_id is Polymarket’s own token id for that side. The bot sends it with the order, so the order goes to the same market the price came from.
Turn on trading
Without --trade the bot only reads prices. To place orders, install Polymarket’s SDK and give the bot the key that signs for your account:
pip install polymarket-client # Python 3.11 or newer export POLYMARKET_PRIVATE_KEY=0x... export POLYMARKET_WALLET=0x... # the wallet address on your Polymarket profile python3 bot.py --league nfl --trade --stake 5 --max-orders 3
For each side whose gap is --min-gap or more, the bot buys --stake dollars at the price in the table or better. Fees come on top. An order fills at once or is cancelled, so nothing is left on the book. It skips games in play and never sells.
Each order is written to orders.json before it is sent. A market recorded there as bought is skipped on later runs, and so is one whose answer never came back, until you check your account and remove its entry. A market where nothing was bought is tried again. Your private key stays on your computer. Polymarket’s SDK signs each order with it locally. Trade once on polymarket.com first, so that wallet is funded and approved.
The order step is new. Start with the default $5 stake. Each order prints bought, none or check.
Work out the cost
A run costs 1 credit for each league, up to 100 games. One league every 10 minutes is 144 credits a day, so the Free plan’s 1,000 credits cover about a week of that. Pricing lists the plans.
Limits
- The gap and the price cap leave out Polymarket’s fees and the cost of moving money in and out.
- A large gap can be a stale price, or news that one side has not caught up with.
- In the run above, the largest gaps were on games ten days away.
- You can lose money. This is a tool and not advice.
The same bot for Kalshi is the Kalshi sports trading bot.
Questions
Do I need a Polymarket key to run it?
Not for the table. The table needs only a dino.markets key. A Polymarket key is needed only when you add --trade.
Does the bot ever sell?
No. It only buys a side that Polymarket prices below the sportsbook fair price. Closing a position is up to you.
Can it leave an order open on the book?
No. Each order fills at once or is cancelled, at the price in the table or better.
What does a run cost?
One credit for each league it reads. The Free plan has 1,000 credits a month.