+Lottery API
Official US lottery winning numbers, draw history, Powerball prize tiers and current jackpots as JSON.
The API.SH Lottery API returns official winning numbers, newest first, for Powerball (with Power Ball, multiplier and Double Play), Mega Millions (Mega Ball and multiplier), New York Lotto, Cash4Life, Take 5, Numbers and Win 4, and Pick 10, with full history back to each game's start in the New York data. Ask for one date or a date range. For one Powerball draw it can add the jackpot, cash value and prize tiers with winners per match level. A second endpoint gives the current estimated jackpots and cash values for the next draw of Powerball, Mega Millions, Lotto America, Millionaire for Life, 2by2 and Jackpot USA.
- 3 endpoints
- from $1 / 1,000 calls
- 1,000 free credits / month
- failed calls free
GET https://api.api.sh/lottery/v1/ games
{ "success": true } What you can build with the Lottery API
Results widgets for news sites
Show the latest Powerball and Mega Millions winning numbers on a news or local site, refreshed after each draw.
Jackpot displays
Display the next draw's estimated jackpot, cash value and draw time for the multi-state games in one call.
Draw history datasets
Page through results for a game over a date range to build a historical dataset for statistics classes or data journalism.
Ticket checking apps
Fetch one draw by date so an app can compare a player's numbers with the official winning numbers and Powerball prize tiers.
Prize payout reporting
Pull a Powerball draw with prizes=true to report national winners and prize amounts per match level, including Power Play.
Lottery data you get
Field names from real responses. Numbers come parsed, URLs absolute, dates in ISO 8601.
Lottery API endpoints and prices
Every Lottery endpoint costs 1 credit per call: credits are $1 per 1,000 on a monthly plan, $2 pay-as-you-go. Pricing
| Lottery games /lottery/ | $1 · $2 PAYG 1 credit |
| Lottery jackpots /lottery/ | $1 · $2 PAYG 1 credit |
| Lottery results /lottery/ | $1 · $2 PAYG 1 credit |
Call the Lottery API
Lottery games: GET https://api.api.sh/lottery/
curl "https://api.api.sh/lottery/v1/games" \
-H "x-api-key: $APISH_KEY" import os, requests
res = requests.get(
"https://api.api.sh/lottery/v1/games",
params={},
headers={"x-api-key": os.environ["APISH_KEY"]},
timeout=120,
)
res.raise_for_status()
data = res.json() const url = new URL("https://api.api.sh/lottery/v1/games");
const res = await fetch(url, { headers: { "x-api-key": process.env.APISH_KEY } });
if (!res.ok) throw new Error(`${res.status} ${await res.text()}`);
const data = await res.json(); # Google Sheets (API.SH add-on)
=APISH("/lottery/v1/games")
# Zapier, Make, n8n (verified node): pick the API.SH app,
# choose "Lottery" and "Lottery games".
# AI agents (Claude, ChatGPT, Cursor): add the
# API.SH MCP server https://api.sh/mcp - Create a free accountConfirm your email and get 1,000 free credits every month. No card needed.
- Create an API keyOne key works for all 483 platforms.
- Send the requestJSON back in one call. Add
output=csvoroutput=ndjsonfor files.
Why API.SH for Lottery data
- Public data only: no Lottery login, cookies or account needed
- One key and one response shape for Lottery and 482 other platforms
- Built and maintained by API.SH, not third-party publishers
- Pay per call; errors on our side cost nothing
- Live status for every endpoint
API.SH vs the official Lottery API
Most US lotteries publish results on their websites rather than through a documented public API; New York publishes its draw history as open data, which this endpoint uses for the New York games. API.SH returns these official numbers and jackpots in one JSON shape with date filters and pagination.
Downtack and RapidAPI lottery listings cover UK and European games; GitHub projects cover single national lotteries. API.SH covers the US games listed here (not EuroMillions or the UK National Lottery) with one key shared with the rest of its data.
Lottery API questions
What lottery data can I get?+
Winning numbers and draw history for Powerball, Mega Millions, New York Lotto, Cash4Life, Take 5, Numbers and Win 4, and Pick 10 (/lottery/v1/results), current jackpots for the next draw of the multi-state games (/lottery/v1/jackpots), and the list of covered games (/lottery/v1/games).
How much does the lottery results API cost?+
Every Lottery endpoint costs 1 credit per call. On a monthly plan 1,000 credits cost $1 (Starter is $50/month for 50,000 credits). Pay-as-you-go is $2 per 1,000 credits, with top-ups from $15 that never expire.
Is there a free lottery results API?+
Yes. Every account gets 1,000 free credits every month. That is 1,000 calls to /lottery/v1/games at 1 credit each. Some free projects on GitHub cover single lotteries; API.SH gives you US results, history and jackpots behind one key.
Where does the data come from?+
Official published winning numbers and prize figures for each game; full draw history for the games in the New York data, plus each game's published jackpot estimates for the next draw.
Do I need keys for the underlying sources?+
No. One API.SH key covers every lottery endpoint. There is nothing to register with the lotteries themselves.
Is there a Powerball API?+
Yes. Call /lottery/v1/results with game=powerball for winning numbers, Power Ball, multiplier and Double Play, add a date and prizes=true for jackpot, cash value and prize tiers, and use /lottery/v1/jackpots for the next estimated jackpot.
Can I get historical lottery results?+
Yes. Pass from and to dates and page through the results with next_page. History goes back to each game's start in the New York data. API.SH provides data only and does not predict numbers.
How do I get started?+
1. Sign up at api.sh. 2. Copy your API key. 3. Call /lottery/v1/results with game=powerball. Every parameter and request example is in the docs at https://api.sh/docs. You can also use the JS or Python SDK, Google Sheets, Zapier, Make, n8n or the MCP server at https://api.sh/mcp so an AI agent can call it.