# Walmart Category Product Scraper – Prices & Listings (`lukehunter/walmart-category-scraper`) Actor

Export Walmart category listings for price monitoring and catalog research: current and was prices, unit price, availability, ratings, seller, images, and product URLs. Enter one category reference - not a list of URLs - and get up to ~1,250 products per category.

- **URL**: https://apify.com/lukehunter/walmart-category-scraper.md
- **Developed by:** [Luke Hunter](https://apify.com/lukehunter) (community)
- **Categories:** E-commerce, Automation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

$3.00 / 1,000 products

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Walmart Category Scraper — Product Prices & Listings

Scrape **Walmart category pages** into clean, structured product data. Enter one or more Walmart category references or browse URLs and get product names, current prices, was-prices, unit prices, availability, ratings, review counts, sellers, sponsored-placement flags, images, and product URLs.

This Actor is built specifically for **Walmart category research**: browse an aisle, paginate it automatically, de-duplicate products, and export the category as a dataset without collecting product URLs one by one.

**[Try the Walmart Category Scraper on Apify](https://apify.com/lukehunter/walmart-category-scraper)**

### Why use this Walmart category scraper?

| Need | What this Actor gives you |
|---|---|
| Scrape a Walmart category | Paste a browse URL or use its `<slug>/<id>` category reference |
| Price monitoring | Numeric current price, pre-markdown price, and unit-price display |
| Category intelligence | Products across up to 25 browse pages per category |
| Ad analysis | `isSponsored` identifies Walmart-sponsored placements |
| Seller research | Seller name plus availability fields |
| Product comparison | Ratings, review counts, brand, description, image, and product link |
| Predictable spend | `maxItems` is a hard cap on delivered products and therefore on cost |
| Clean exports | Flat rows ready for CSV, Excel, JSON, databases, or the Apify API |

The key focus is **category-level product and price data**, not keyword search or one-product-at-a-time scraping.

### What can you do with Walmart category data?

#### Monitor prices across a Walmart category

Collect current prices across an aisle and schedule the same category to run again later. Use `usItemId` as the stable product identifier when comparing runs.

#### Find Walmart markdowns

`price` contains the current price and `priceWas` contains the previous comparison price when Walmart publishes a markdown.

#### Analyze sponsored vs. organic products

Every delivered product includes `isSponsored`, so paid placements can be separated from the rest of the category.

#### Compare sellers, ratings, and assortment

Use `sellerName`, `averageRating`, `numberOfReviews`, availability, and product identity fields to analyze what Walmart is currently showing in a category.

#### Export Walmart category products

Every run writes a standard Apify dataset that can be downloaded as CSV, Excel, JSON, or accessed programmatically through the Apify API.

### How to scrape a Walmart category

1. Open a category on Walmart.com.
2. Copy the browse URL, for example:
   `https://www.walmart.com/browse/food/976759`
3. Paste the full URL into **Walmart categories**, or enter just:
   `food/976759`
4. Set **Maximum products**.
5. Click **Start**.
6. Export the resulting dataset or use it through the API.

You can enter up to 20 categories in one run.

### Input

```json
{
  "categories": [
    "food/976759",
    "household-essentials/1115193"
  ],
  "maxItems": 100,
  "maxPagesPerCategory": 25
}
```

| Field | Type | Default | Description |
|---|---|---:|---|
| `categories` | string\[] | required | 1–20 Walmart category references or full browse URLs |
| `maxItems` | integer | 100 | 1–5000. Hard cap on products delivered across the whole run |
| `maxPagesPerCategory` | integer | 25 | 1–25. Safety cap on category browse pages fetched |

For most users, the only settings that matter are **Walmart categories** and **Maximum products**.

### Walmart product data fields

| Category | Fields |
|---|---|
| Identity | `usItemId`, `category` |
| Product | `name`, `brand`, `shortDescription` |
| Price | `price`, `priceWas`, `currency`, `unitPriceDisplay` |
| Availability | `availabilityStatus`, `availabilityDisplay` |
| Social proof | `averageRating`, `numberOfReviews` |
| Seller & ads | `sellerName`, `isSponsored` |
| Media & links | `imageUrl`, `productUrl` |
| Freshness | `scrapedAt` |

Missing values are returned as `null`. The Actor does not invent missing product data.

### Walmart output example

```json
{
  "usItemId": "44391605",
  "name": "Fresh Strawberries, 1 lb Container",
  "brand": null,
  "category": "food/976759",
  "price": 1.97,
  "priceWas": 3.14,
  "currency": "USD",
  "unitPriceDisplay": "12.3 ¢/oz",
  "availabilityStatus": "IN_STOCK",
  "availabilityDisplay": "In stock",
  "averageRating": 4.5,
  "numberOfReviews": 1203,
  "sellerName": "Walmart.com",
  "isSponsored": false,
  "imageUrl": "https://i5.walmartimages.com/seo/example.jpeg",
  "productUrl": "https://www.walmart.com/ip/Fresh-Strawberries-1lb-Container/44391605",
  "scrapedAt": "2026-09-20T00:00:00.000Z"
}
```

### Why the Walmart price extraction is useful

Walmart category-page data does not always put the usable price in the most obvious top-level field. This Actor reads Walmart's structured price lines and recognizes both regular current prices and markdown pricing.

That matters because a markdown can be represented as a discounted price with a separate comparison or was-price. The Actor exposes those as:

- `price` — current product price
- `priceWas` — previous comparison price when published
- `unitPriceDisplay` — Walmart's own per-unit price text

This makes the dataset more useful for category price monitoring than a parser that only reads one top-level price field.

### Use it as a Walmart category API

The Actor can be called from your own application through the Apify API. No Walmart API key or Walmart login is required.

#### Python

```python
from apify_client import ApifyClient

client = ApifyClient("YOUR_APIFY_TOKEN")

run = client.actor("lukehunter/walmart-category-scraper").call(
    run_input={
        "categories": ["food/976759"],
        "maxItems": 100,
        "maxPagesPerCategory": 25,
    }
)

for product in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(product["name"], product["price"], product["sellerName"])
```

Use Apify schedules for recurring category snapshots, and webhooks or integrations to send completed datasets into the rest of your workflow.

### Pricing and cost control

This Actor uses **pay per delivered product** pricing.

**Current configured rate: $0.003 per product delivered.** Check the Apify **Pricing** tab for the latest published rate.

| Products delivered | Cost at $0.003/product |
|---:|---:|
| 100 | $0.30 |
| 1,000 | $3.00 |
| 5,000 | $15.00 |

There is no charge for merely starting a run. `maxItems` gives you a clear upper bound on the number of billable products.

Products are de-duplicated by `usItemId` within a run.

### Reliability and data quality

The Actor is designed to make data problems visible instead of hiding them.

- If Walmart blocks a category before any products are found, the run fails instead of returning an apparently successful empty dataset.
- Built-in quality checks detect malformed or degraded Walmart responses and reject pages that no longer look like normal product data instead of quietly treating them as valid.
- Individual products can still have fields that Walmart does not provide. Missing values are returned as `null` rather than guessed.
- Sponsored products are delivered but explicitly labelled with `isSponsored`.
- Products without a usable `usItemId` are dropped rather than risking incorrect de-duplication.
- Missing values remain `null`; they are not guessed.

### Important limitations

- **Category browsing, not keyword search.** This Actor does not build Walmart `/search` queries.
- Walmart exposes a practical ceiling of about **25 pages per category**, roughly 1,250 products when pages contain around 50 products.
- Up to **20 categories per run**.
- **No store or ZIP input.** Walmart pricing and availability can vary by location. This Actor reflects the category-page context Walmart serves to the request and should not be treated as guaranteed store-specific inventory.
- Availability fields reflect what Walmart publishes on the category page, not a live stock check at a specific store.
- Prices, ratings, sellers, and availability can change after the run. `scrapedAt` records the observation time.
- The Actor does not use CAPTCHA bypass, proxy rotation, credential capture, or impersonation.
- Public catalogue data only; no personal data is collected.
- This is an independent tool and is **not affiliated with, endorsed by, or connected to Walmart Inc.** Walmart is a trademark of its owner. You are responsible for using the data in accordance with applicable terms and laws.

### FAQ

#### Can I scrape all products in a Walmart category?

The Actor pages through the category until it reaches Walmart's available pages, your `maxItems` limit, or your `maxPagesPerCategory` limit. Walmart category browsing itself has a practical ceiling of about 25 pages.

#### How do I find the Walmart category ID?

Open the category on Walmart.com. For a URL such as:

```text
https://www.walmart.com/browse/food/976759
```

you can enter either the whole URL or the final two path segments:

```text
food/976759
```

#### Can I export Walmart products to CSV or Excel?

Yes. Every run writes a standard Apify dataset that can be exported as CSV, Excel, JSON, and other supported formats.

#### Can I track Walmart price changes?

Yes. Schedule the same category to run repeatedly and compare products by `usItemId`. `price` gives the current value and `priceWas` captures a published comparison price when available.

#### Does it identify sponsored Walmart products?

Yes. `isSponsored` is `true` when Walmart marks the product as a sponsored placement.

#### Does it scrape Walmart search results?

No. It is deliberately focused on category browse pages.

#### Can I scrape prices for a specific Walmart store or ZIP code?

No. This Actor does not currently accept a store or ZIP input.

#### Do I need a Walmart API key or account?

No separate Walmart API key or Walmart login is required.

#### How do I control the cost?

Set `maxItems`. It is a hard cap on the number of products delivered across the run and therefore on billable results.

# Actor input Schema

## `categories` (type: `array`):

Walmart category references, as "<slug>/<id>" from the browse URL, or the full browse URL itself. For https://www.walmart.com/browse/food/976759 that is food/976759. Covers complete category listings; keyword search is not supported. Maximum 20 categories per run.

## `maxItems` (type: `integer`):

Hard cap on the number of products delivered across all categories. You are charged per delivered product, so this is your cost cap.

## `maxPagesPerCategory` (type: `integer`):

Safety cap on how many browse pages are fetched per category (each page holds roughly 50 products). Walmart itself only ever exposes up to 25 pages (~1,250 products) per category, so this cannot be set higher — lower it to sample a large category faster.

## Actor input object example

```json
{
  "categories": [
    "food/976759",
    "household-essentials/1115193"
  ],
  "maxItems": 100,
  "maxPagesPerCategory": 25
}
```

# Actor output Schema

## `products` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "categories": [
        "food/976759",
        "household-essentials/1115193"
    ],
    "maxItems": 100,
    "maxPagesPerCategory": 25
};

// Run the Actor and wait for it to finish
const run = await client.actor("lukehunter/walmart-category-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "categories": [
        "food/976759",
        "household-essentials/1115193",
    ],
    "maxItems": 100,
    "maxPagesPerCategory": 25,
}

# Run the Actor and wait for it to finish
run = client.actor("lukehunter/walmart-category-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "categories": [
    "food/976759",
    "household-essentials/1115193"
  ],
  "maxItems": 100,
  "maxPagesPerCategory": 25
}' |
apify call lukehunter/walmart-category-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,lukehunter/walmart-category-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/T1aBbCVie6FArGNd3/builds/OkCkeorAYj14RkpK0/openapi.json
