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
3mo 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 →
identify.plantnet.org API
Identify and explore plant species by searching through Pl@ntNet's comprehensive botanical database to access detailed information like taxonomic families, genera, species descriptions, photos, and community observations. Track plant distributions, view contribution trends, and discover expert contributors within the platform's collaborative plant identification community.
data.lime.bike API
Access real-time availability data for Lime bikes and scooters, including station locations, vehicle status, system alerts, and geofencing zones across multiple cities. Monitor micromobility inventory and service information to find nearby vehicles or plan your trips effectively.
accessdata.fda.gov API
Search and retrieve comprehensive FDA premarket approval information for medical devices, including approval status, supplements, applicant details, and advisory committee data. Get instant access to specific PMA records with all relevant approval information in one place.
eprocurement.gov API
Monitor India's public procurement opportunities by accessing active tenders, bids closing today, global tenders, high-value contracts, and cancelled tenders from the Central Public Procurement Portal. Search tender details, browse participating organizations, and track real-time procurement statistics to stay informed on government contracting opportunities.
cmegroup.com API
Get CME Group market data including FedWatch interest-rate probabilities, futures quotes and settlements, volume/open interest history, and options expirations and near-the-money option chains.
alienvault.com API
Search and analyze global threat intelligence data including indicators of compromise, threat pulses, and adversary profiles from the Open Threat Exchange community. Monitor recent security alerts and access detailed information about threats and adversaries to strengthen your cybersecurity defenses.
api.nasa.gov API
Access NASA's suite of open data APIs — including the Astronomy Picture of the Day, Near Earth Object tracking, DONKI space weather events, EPIC Earth imagery, Mars weather, the NASA Image and Video Library, the Exoplanet Archive, and EONET natural events.
mahatenders.gov.in API
Access Maharashtra government tenders from mahatenders.gov.in, browsing them by closing date or by organization with full tender details and pagination support. Find and review procurement opportunities across different government departments in one place.
New York Lottery API – Draw Results & Data · Parse