Web Scraping Zomato: A Step-by-Step Python Guide to Restaurants, Menus & Ratings (2026) Get The Full Insight ✕

Grocery APIs in 2026: Every Way to Get Grocery Product & Price Data

Grocery APIs in 2026 Every Way to Get Grocery Product & Price Data

A grocery API is a programmatic way to get supermarket data: product names, sizes, prices, promotions, stock, and store locations. You have three kinds of options. Official retailer APIs, such as Kroger’s and Walmart’s, give accurate data for one retailer each, often with approval requirements and daily limits. Free open datasets, such as Open Food Facts and government price series, cover product details or national averages, not live store prices. Grocery data APIs combine many retailers into one feed with store- or ZIP-level prices. Which one you need depends on how many retailers, which locations, and how fresh the data has to be.

This guide compares all three, with what each official API actually returns, where it stops, and working code for Kroger’s API.

Key takeaways

  • Kroger has the most open official grocery API. Anyone can register, and it returns real store prices, but only per store (you must pass a location ID) and within daily call limits.
  • Walmart’s product and price APIs are for approved partners, mainly affiliates and sellers. Access is selective.
  • Instacart’s Developer Platform isn’t a price-lookup API. It sends shopping lists and recipes to Instacart, where shoppers see prices.
  • Amazon retired its Product Advertising API (PA-API 5.0) in 2026. The Creators API replaces it for Amazon Associates.
  • Most chains have no public price API at all, including Target, Costco, Albertsons/Safeway, Aldi, Publix and H-E-B, as well as India’s Blinkit, Zepto and Instamart.
  • Free open data is useful but different. Open Food Facts covers product details, Open Prices has crowd-sourced prices, and the US BLS publishes national monthly average prices.

What is a grocery API?

A grocery API returns structured supermarket data in machine-readable form, usually JSON, instead of a web page. Most fall into six types:

TypeWhat it returnsTypical users
Product catalog APINames, brands, sizes, categories, images, UPC/GTIN barcodesApps, marketplaces, recipe platforms
Grocery price APIRegular price, sale/promo price, unit price, per store or ZIP codePricing teams, price-comparison apps, analysts
Inventory/availability APIIn-stock status, stock levels by storeRetailers, delivery apps
Store locator APIStore IDs, addresses, hours, departmentsApps that need a store before a price
Ordering/delivery APICarts, orders, delivery slotsRetail partners, meal-kit and recipe apps
Nutrition & ingredients APINutrition facts, ingredients, allergensHealth, diet and recipe apps

Most people searching for a “grocery API” need the price type, which is also the hardest to get.

Official retailer grocery APIs compared

Only a few grocers publish APIs, and each one is built for its own purpose, not for comparing prices across stores.

APIWho can use itReturns prices?CoverageThe catch
Kroger Developer APIs (Products, Locations, Cart)Anyone who registersYes: regular and promo priceKroger-family stores onlyPrices only per store (needs a locationId); daily call caps
Walmart APIs (walmart.io affiliate APIs, Marketplace API)Approved affiliates and partners; sellers for MarketplaceAffiliate APIs: yesWalmart onlyApproval is selective; Marketplace covers only a seller’s own listings
Instacart Developer PlatformApp developers with an API keyNot as a data feedHands off to Instacart’s retailersCreates shopping-list and recipe pages on Instacart; it isn’t a price-lookup service
Amazon Creators API (replaced PA-API 5.0 in 2026)Amazon AssociatesProduct offers for affiliate useAmazon listingsBuilt for affiliate links, not store-level grocery price monitoring
Target, Costco, Albertsons/Safeway, Aldi, Publix, H-E-B—No public price API—Data only via their websites and apps
Tesco, Sainsbury’s, Asda (UK)—No public price API—Same
Blinkit, Zepto, Swiggy Instamart, BigBasket (India)—No public price API—Same

Kroger. The most useful official option for price data. Register an app at developer.kroger.com, get a client ID and secret, and call the Products API with a store’s locationId to see that store’s regular and promo prices. Without a location ID, no price comes back. Developers report limits of about 10,000 Products API calls and 1,600 Locations API calls per day, which is plenty for an app but not for monitoring thousands of products across hundreds of stores. The Cart API can add items to a signed-in customer’s cart. See the code example below and FoodSpark’s Kroger API for multi-store coverage.

Walmart. Walmart’s developer portal (walmart.io) offers affiliate-oriented product and price APIs to approved partners, and the Marketplace API lets sellers manage their own listings and prices. Both depend on approval. Neither is an open window into Walmart’s full catalog at every store. For monitoring, see FoodSpark’s Walmart API.

Instacart. The Instacart Developer Platform lets an app send a shopping list or recipe to Instacart, where the shopper picks a store and sees current prices. It’s a useful handoff for recipe and meal-planning apps, but it doesn’t give you a price table to analyse. Retailers use a separate set of Instacart Connect APIs for fulfilment. For store- and ZIP-level Instacart pricing, see scraping Instacart store pricing by city and ZIP code and FoodSpark’s Instacart API.

Amazon. Amazon retired its Product Advertising API (PA-API 5.0) in 2026 and moved Associates to the Creators API. It’s designed for building affiliate links, and grocery availability on Amazon Fresh and Whole Foods depends on your delivery location. For grocery pricing, see FoodSpark’s Amazon Fresh API.

Free and open grocery data sources

If you don’t need live store prices, several free sources are worth knowing before you pay for anything:

SourceWhat it gives youPrices?Best for
Open Food FactsOpen, worldwide database of food products by barcode: ingredients, nutrition, allergens, Nutri-Score, imagesNoProduct details and barcode lookups
Open Prices (by Open Food Facts)Crowd-sourced prices submitted from receipts and shelf tags, with a free APIYes, but coverage depends on volunteersResearch and spot checks, not systematic monitoring
USDA FoodData CentralUS nutrition data, including branded products with UPC/GTIN codes, via a free API keyNoNutrition and ingredient apps
US BLS Average Price DataMonthly average US retail prices for staples such as eggs, milk, bread and ground beef, national and regional, through the BLS Public Data APIAverages onlyFood inflation and trend analysis

These are excellent for product data and macro trends. What none of them gives you is today’s price for a specific product at a specific store, or a competitor’s promotion this week. That’s the gap retailers, brands, and apps usually need filled.

Where official APIs stop, and where grocery data APIs fit

Official APIs answer “what does this one retailer charge at this one store?” Most grocery questions are bigger than that:

  • Comparing retailers. Walmart vs Kroger vs Target vs Costco for the same basket needs one consistent feed, and most of those chains don’t have an API at all.
  • Location coverage. Grocery prices vary by store and ZIP code. Pulling hundreds of stores through Kroger’s per-store lookups runs into daily caps quickly.
  • Promotions and unit prices. Sale prices, multi-buy offers, and price-per-ounce need to be captured and normalised consistently across retailers.
  • History. Price tracking needs daily or weekly snapshots, stored and compared, not a live lookup.
  • Markets without APIs. India’s quick-commerce apps (Blinkit, Zepto, Swiggy Instamart), UK supermarkets and most regional US chains publish no price APIs.

A grocery data API fills that gap. The provider collects public product and price data from retailers’ websites and apps, normalises it into one schema, and delivers it by API or scheduled feed, by store, ZIP code or city. That’s what FoodSpark’s grocery data API and grocery data scraping API do, with retailer-specific feeds such as Costco, Safeway, Blinkit and Zepto. For India’s 10-minute delivery apps specifically, see our quick commerce data API guide.

NeedBest option
One app, Kroger stores onlyKroger’s official API
Affiliate links to Walmart or Amazon productsWalmart affiliate APIs or Amazon Creator API
Send a recipe or shopping list to shoppersInstacart Developer Platform
Product details, barcodes, nutritionOpen Food Facts or USDA FoodData Central
National food-price trendsBLS Average Price Data
Prices across many retailers, stores or ZIP codes, tracked over timeA grocery data API

What a good grocery price API should return

A usable grocery price record answers five questions: what product, where, at what price, on what promotion, and when.

GroupFields to expect
IdentifiersUPC/GTIN barcode, retailer SKU, product URL
ProductName, brand, size, pack count, category
PriceRegular price, sale price, member/loyalty price, unit price (per oz, lb, kg or litre), currency
PromotionOffer text, multi-buy terms (for example, “2 for $5”), start and end dates
AvailabilityIn stock, out of stock, limited stock
LocationRetailer, store ID, ZIP/postal code, city
TimeWhen the price was captured

Example record (illustrative):

{
  "retailer": "example-grocer",
  "store_id": "0142",
  "zip_code": "45202",
  "captured_at": "2026-09-25T06:00:00Z",
  "product": {
    "name": "2% Reduced Fat Milk",
    "brand": "Example Brand",
    "size": "1 gal",
    "upc": "000000000000",
    "category": "Dairy > Milk"
  },
  "price": {
    "regular": 3.49,
    "sale": 2.99,
    "member_only": true,
    "unit_price": 0.023,
    "unit": "fl oz",
    "currency": "USD"
  },
  "promotion": { "text": "Member price through Oct 1" },
  "availability": "in_stock"
}

How to choose a grocery price API:

  1. Coverage. Does it include the retailers and regions you compete in, including the ones with no official API?
  2. Location detail. Are prices by store or ZIP code, or national averages? Grocery prices genuinely differ by location.
  3. Freshness. How often is each price refreshed, and does every record carry a timestamp?
  4. Promotions. Are regular, sale, and member prices kept in separate fields, or blended into one number?
  5. Normalisation. Are unit prices calculated, and are identical products matched across retailers (ideally by UPC)?
  6. History. Can you get past prices, not just today’s?
  7. Delivery. REST API, webhooks, or scheduled CSV/JSON files to your cloud storage?
  8. Compliance. Is the data limited to public product and price information, with no personal data?
  9. A real sample. Test a sample from your own target stores before you commit.

Code example: get store prices from the Kroger API

Kroger’s API is the easiest official way to see real grocery prices in code. It takes three calls: get an access token, find a store near a ZIP code, then search products at that store.

Before you start: register at developer.kroger.com, create an app, and copy its client ID and client secret. Then pip install requests.

import base64

import requests

CLIENT_ID = "your-client-id"          # from developer.kroger.com
CLIENT_SECRET = "your-client-secret"
BASE = "https://api.kroger.com/v1"


def get_token():
    """Get an app-level access token (client credentials) with product read access."""
    auth = base64.b64encode(f"{CLIENT_ID}:{CLIENT_SECRET}".encode()).decode()
    response = requests.post(
        f"{BASE}/connect/oauth2/token",
        headers={"Authorization": f"Basic {auth}",
                 "Content-Type": "application/x-www-form-urlencoded"},
        data={"grant_type": "client_credentials", "scope": "product.compact"},
        timeout=30,
    )
    response.raise_for_status()
    return response.json()["access_token"]


def nearest_store(token, zip_code):
    """Prices are store-specific, so find a store (locationId) first."""
    response = requests.get(
        f"{BASE}/locations",
        headers={"Authorization": f"Bearer {token}"},
        params={"filter.zipCode.near": zip_code, "filter.limit": 1},
        timeout=30,
    )
    response.raise_for_status()
    store = response.json()["data"][0]
    return store["locationId"], store.get("name", "")


def search_prices(token, term, location_id):
    """Search products at one store and return name, size, regular and promo price."""
    response = requests.get(
        f"{BASE}/products",
        headers={"Authorization": f"Bearer {token}"},
        params={"filter.term": term, "filter.locationId": location_id, "filter.limit": 10},
        timeout=30,
    )
    response.raise_for_status()
    rows = []
    for product in response.json().get("data", []):
        for item in product.get("items", []):
            price = item.get("price") or {}
            rows.append({
                "product": product.get("description"),
                "brand": product.get("brand"),
                "size": item.get("size"),
                "regular": price.get("regular"),
                "promo": price.get("promo"),
            })
    return rows


if __name__ == "__main__":
    token = get_token()
    location_id, store_name = nearest_store(token, "45202")  # a Cincinnati ZIP code
    for row in search_prices(token, "milk", location_id):
        print(store_name, row)

What it returns: one row for each product size, with the regular price and the promo price for the store you picked. Change the ZIP code, and you may see different prices. That’s the per-store behaviour described above, and it’s why a location ID is required.

Where this stops: one retailer, one store per call, and a daily call budget. To compare Kroger with Walmart, Target, or Costco across many stores and ZIP codes every day, you need a multi-retailer feed rather than more of these calls.

What teams build with grocery price APIs

  • Competitive price monitoring. Retailers and brands track rivals’ shelf and online prices by store and ZIP code, and react to price moves within days rather than quarters.
  • Price-comparison and budgeting apps. Consumer apps show which nearby store has the cheapest basket, which needs matched products and unit prices across retailers.
  • Promotion and loyalty analysis. Brands check how often, how deeply, and where their products and competitors’ products are discounted, including member-only prices.
  • Assortment and availability tracking. Category teams see which products each retailer stocks in each region, and how often they’re out of stock.
  • Quick-commerce benchmarking in India. Teams compare Blinkit, Zepto, and Swiggy Instamart prices and delivery by pincode. See our Blinkit vs Zepto vs Instamart price benchmarking guide.
  • Food inflation research and AI products. Analysts and AI teams combine store-level prices with BLS averages to model price trends, or feed current prices into shopping and meal-planning assistants.

Get Started

One Grocery API for Every Retailer

Kroger’s API covers one chain and one store at a time, and most retailers have no API at all.

Get a Free Grocery Price Sample
cta-bg

Frequently asked questions

What is a grocery API?

A grocery API is a programmatic way to get supermarket data, such as products, prices, promotions, stock, and store locations, as structured data (usually JSON) instead of web pages. It can come from a retailer (like Kroger’s official API), from an open dataset (like Open Food Facts), or from a data provider that combines many retailers.

Is there a free grocery price API?

Yes, with limits. Kroger’s official API is free to register for and returns store-level prices, but only for Kroger-family stores, one store at a time, within daily call limits. Open Prices offers free crowd-sourced prices, and the US BLS publishes free monthly national average prices for staple foods.

Does Walmart have a public grocery price API?

Not an open one. Walmart’s developer APIs, including affiliate product and price APIs and the Marketplace API for sellers, require approval, and the Marketplace API only covers a seller’s own listings. For broad Walmart price monitoring, companies use a grocery data API.

Does the Instacart API return product prices?

Not as a data feed. The Instacart Developer Platform lets apps send shopping lists and recipes to Instacart, where the shopper sees current prices at their chosen store. It isn’t designed for pulling price data for analysis.

How do I get grocery prices by ZIP code or store?

With Kroger’s API, look up a store near the ZIP code with the Locations API, then pass that store’s location ID to the Products API. For other retailers, or for many ZIP codes at once, use a grocery data API that collects store- or ZIP-level prices across retailers.

Which grocery API is best for price comparison?

For comparing several retailers, use a multi-retailer grocery data API, because official APIs cover one retailer each and most chains have none. For a single-retailer app built on Kroger stores, Kroger’s official API is enough.

Are there APIs for Blinkit, Zepto, or Instamart?

None of them publishes a public price API. Businesses that need their prices, availability, and delivery data by pincode use a quick-commerce data API. See our quick commerce data API guide.

Is it legal to use grocery price data from a data API?

Reputable providers collect only publicly displayed product and price information, not personal data. Retailers’ terms of use still apply, so for a commercial project, review how your provider sources its data and check with your legal team.

Conclusion

Start with the free options. If Kroger stores alone are enough, Kroger’s official API gives you real store prices today. For product details and national trends, Open Food Facts, USDA FoodData Central, and BLS average prices cost nothing. But if the question is “what are Walmart, Kroger, Target, Costco and Safeway charging for this basket in these ZIP codes, every week?”, or the same question for Blinkit and Zepto by pincode, no official API will answer it.

That’s the gap FoodSpark’s grocery data API fills: one normalised feed of product, price, promotion, and availability data across retailers and locations, delivered by API or scheduled file, with a free sample so you can check it against your own target stores.

Looking at a specific retailer? See the Kroger, Walmart, Instacart, and Amazon Fresh APIs.

Table of Contents

Need Custom Food Data?
  • Custom Food Data Solutions
  • Choose Platforms, Fields, Formats
  • Flexible Data Delivery Formats

Grocery APIs in 2026: Every Way to Get Grocery Product & Price Data

Grocery APIs in 2026 Every Way to Get Grocery Product & Price Data

Table of Contents

Explore Our Latest Insights