Discover/nylottery.ny.gov API
live

nylottery.ny.gov APInylottery.ny.gov

Access NY Lottery draw results, historical winning numbers, scratch-off games, retailer locations, and winner data via 7 structured endpoints.

Endpoints
7
Updated
4mo ago
Try it

No input parameters required.

api.parse.bot/scraper/9211b077-5bb6-4e8f-88f3-6e88cadf6d85/<endpoint>
Ready to send
Fill in the parameters and hit sign in to send to see live response data here.
Use it in your codegrab a free API key at signup
curl -X GET 'https://api.parse.bot/scraper/9211b077-5bb6-4e8f-88f3-6e88cadf6d85/get_latest_draws' \
  -H 'X-API-Key: $PARSE_API_KEY'
All endpoints · 7 totalclick to expand

Get latest draw results and jackpot information for all New York Lottery draw games. Returns data for cash4life, powerball, lotto, megamillions, million4life, pick10, numbers, take5, win4, quickdraw, and raffle.

Input

No input parameters required.

Response
{
  "type": "object",
  "fields": {
    "data": "object containing game keys (cash4life, powerball, lotto, megamillions, etc.) each with draws array, next_draw timestamp, and last_draw timestamp"
  },
  "sample": {
    "data": {
      "data": {
        "status": "SUCCESS",
        "statusCode": 200,
        "megamillions": {
          "draws": [
            {
              "status": 4,
              "drawTime": 1778817600000,
              "gameName": "megamillions",
              "drawNumber": 2505,
              "estimatedJackpot": 251000000
            }
          ],
          "gameId": "12",
          "last_draw": 1778637615000,
          "next_draw": 1778896815000
        }
      }
    },
    "status": "success"
  }
}

About the nylottery.ny.gov API

This API exposes 7 endpoints covering the full breadth of New York Lottery data, from live draw results across 11 games to retailer geosearch and scratch-off prize inventories. The get_latest_draws endpoint returns current jackpot figures and the most recent winning numbers for every active draw game in a single call, while get_number_frequency delivers computed frequency statistics without any client-side aggregation.

Draw Results and Game Coverage

The get_latest_draws endpoint returns a single object whose keys map to each game — cash4life, powerball, lotto, megamillions, take5, win4, numbers, pick10, quickdraw, million4life, and raffle. Each game block contains a draws array, a next_draw timestamp, and a last_draw timestamp. For per-game detail, get_game_draws accepts a game string parameter and returns the 10 most recent draws with winning numbers, jackpot estimates, and draw metadata.

Historical Records and Frequency Analysis

get_historical_results pulls from data.ny.gov and supports start_date and end_date filters in YYYY-MM-DD format alongside limit and offset for pagination. Each record in the returned array includes draw_date, winning_numbers, and game-specific bonus fields. The get_number_frequency endpoint builds on this history: pass a game name and an optional lookback integer to receive main_numbers and bonus_numbers arrays, each sorted by frequency descending, plus a total_records_analyzed count. Games without a bonus ball return null for bonus_numbers.

Scratch-Offs, Retailers, and Winners

get_scratch_off_games lists all active instant games with ticket_price, top_prize_amount, top_prize_remaining, and overall_odds per entry. search_retailers accepts lat, lon, and miles parameters and returns paginated retailer records including field_street_address, field_city, field_state, field_zipcode, and a field_geofield coordinate object. The pager object on that response exposes total_items, total_pages, and items_per_page. get_recent_winners is also paginated (0-indexed page parameter) and returns winner name, prize, prize_type, date, location, and a body narrative field.

Common use cases
  • Build a jackpot tracker dashboard that polls get_latest_draws to show current Powerball and Mega Millions estimates.
  • Analyze hot and cold numbers for Take 5 or Win 4 by calling get_number_frequency with a custom lookback window.
  • Display active scratch-off games filtered by ticket_price or sorted by top_prize_remaining to surface games with prizes still available.
  • Integrate a retailer locator into a mobile app using search_retailers with user device coordinates and a configurable miles radius.
  • Archive full draw history for any game by paginating get_historical_results with start_date and end_date over multi-year ranges.
  • Populate a winner stories feed using get_recent_winners with the body, location, and prize fields.
  • Automate alerts when the next Lotto or Cash4Life draw approaches using next_draw timestamps from get_game_draws.
Pricing & limitsSee full pricing →
TierPriceCredits/monthRate limit
Free$0/mo1005 req/min
Hobby$30/mo1,00020 req/min
Developer$100/mo5,000250 req/min

One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.

Frequently asked questions
Does the NY Lottery website have an official public developer API?+
No. The New York Lottery does not publish an official developer API or documented data feed for third-party use. Historical draw data is available as a public dataset on data.ny.gov, which get_historical_results draws from, but there is no official programmatic interface for live draws, scratch-offs, or retailer data.
How does `get_historical_results` differ from `get_game_draws`?+
get_game_draws returns the 10 most recent draws with jackpot estimates and draw metadata from the NY Lottery directly. get_historical_results sources from data.ny.gov and supports arbitrary date ranges via start_date and end_date, plus limit and offset pagination, making it suitable for bulk historical retrieval. The historical records include draw_date and winning_numbers but may not include jackpot estimate fields present in get_game_draws.
Does `get_number_frequency` cover all games, including Quick Draw?+
Frequency analysis is available for any game accepted by the game parameter, including quickdraw. Results depend on how many historical records exist for that game in data.ny.gov. The total_records_analyzed field in the response tells you exactly how many draws the calculation covered for a given lookback value.
Does the API return prize tier breakdowns for each draw — for example, how many tickets matched 4 of 5 numbers?+
Not currently. The draw endpoints return winning numbers, jackpot estimates, and draw timestamps, but per-tier prize payouts and winner counts per tier are not included in the response fields. You can fork this API on Parse and revise it to add an endpoint covering prize tier data if that structure is available from the source.
Is retailer data limited to New York State?+
Yes. search_retailers returns only licensed New York Lottery retailers, so results are bounded by the NY Lottery's own retailer network. Coordinates outside New York may return zero results or retailers near the state border. The pager object confirms total results found for any given search center and radius.
Page content last updated . Spec covers 7 endpoints from nylottery.ny.gov.
Related APIs in Government PublicSee all →
lotteryusa.com API
Check the latest winning numbers and jackpot amounts across all US lotteries, and view detailed prize breakdowns by state and game. Stay updated on lottery results instantly without visiting multiple lottery websites.
lotterypost.com API
Check daily lottery results and jackpot amounts across 20+ US states and multi-state games, plus browse historical drawing data to track past winners and prize trends. Quickly compare results from multiple states or look up specific games all in one place.
powerball.com API
Check the latest Powerball drawing results, historical winning numbers, current jackpot amounts, and prize information all in one place. Browse past draws by date, view odds and prize breakdowns, and explore stories from winners to stay informed about your favorite lottery game.
calottery.com API
Check the latest California Lottery results for Powerball and Mega Millions, including up to 120 recent draws from 2025 and historical data for all available games. Search past winning numbers and game information across California's lottery draw games.
megamillions.com API
Check the latest Mega Millions winning numbers and jackpot amounts, browse historical drawings, and discover the top jackpots across participating lottery states. Stay updated on lottery results and track winning combinations whenever you need them.
usamega.com API
Check the latest Mega Millions and Powerball results, jackpot amounts, and winning odds all in one place. Analyze drawing details and tax implications to make smarter lottery decisions.
sportstoto.com.my API
Access Sports Toto Malaysia lottery jackpots, draw results, and past results calendars. Retrieve winning numbers, prize amounts, and comprehensive 4D frequency statistics for historical analysis.
bet.hkjc.com API
Check the latest Hong Kong Jockey Club Mark Six lottery results with prize breakdowns and view historical frequency statistics for all 49 numbers to analyze winning patterns. Find out when the next draw is scheduled and see detailed information about completed draws.