# Ultimate Costco.com Scraper (`eneiromatos/ultimate-costco-com-scraper`) Actor

Unlock Costco.com product data with the fastest web scraper. Perform high-volume data extraction of real-time pricing, inventory, SKUs, and full product specifications in a structured JSON format. Perfect for e-commerce analytics, price tracking, and deep competitor monitoring.

- **URL**: https://apify.com/eneiromatos/ultimate-costco-com-scraper.md
- **Developed by:** [Eneiro Matos](https://apify.com/eneiromatos) (community)
- **Categories:** E-commerce
- **Security:** Limited permissions
- **Stats:** 4 total users, 0 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

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

## 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

## Ultimate Costco.com Scraper

Unlock **rich product data** from **Costco.com** with the **fastest, most comprehensive web scraper** on the market. This specialized **Costco Web Scraper** is engineered for **speed and precision**, allowing you to perform **high-volume data extraction** and capture a vast array of data fields in a clean, **structured JSON format**.

***

#### Key Data Extraction Features

While other **data scrapers** barely scratch the surface, this powerful **costco data extraction tool** dives deep to pull **extensive product details**, including:

- **Real-time Pricing Data** (for **price tracking** and **competitive analysis**)

- **Inventory** and **Stock Availability**

- **Product Categories** and **Navigation Trails**

- **Detailed Product Specifications** (**specs**)

- **High-Resolution Product Images** and **Media**

- **All Product Variations** (**SKUs**) and **Options**

- **Customer Reviews** and **Ratings** (for **sentiment analysis**)

***

#### Use Cases & Target Audience

The high-quality, **structured e-commerce data** is perfect for **e-commerce analytics**, **competitor monitoring**, **market research**, **dynamic pricing**, **building robust product databases**, and **inventory management**. Leverage this **Costco data mining tool** to gain a significant **competitive advantage** in the retail landscape.

### Input

The actor provides multiple ways to scrape data: by direct product URLs, category/listing URLs, or keyword searches.

#### Sample Input

Here is a valid JSON object for running the scraper:

```json
{
  "productUrls": ["https://www.costco.com/p/-/physiogel-daily-moisture-therapy-pro-b5-lotion-71-fl-oz-2-pack/4000388448"],
  "listingUrls": ["https://www.costco.com/bath-body.html"],
  "keywords": ["body gel"],
  "useApifyProxy": true,
  "startPageNumber": 0,
  "finalPageNumber": 0
}

```

#### Input Field Explanations

You can use any combination of `productUrls`, `listingUrls`, and `keywords`.

- **`productUrls`** (Array<string>): A list of direct URLs for specific Costco product pages you want to scrape.

- **`listingUrls`** (Array<string>): A list of category or search result URLs. The scraper will find all product links on these pages and scrape them.

- **`keywords`** (Array<string>): A list of search terms. The scraper will perform a search for each keyword on Costco.com and scrape the resulting products.

- **`useApifyProxy`** (boolean): If set to `true`, the scraper will use the Apify Proxy for requests. This is highly recommended for reliable scraping at scale.

- **`startPageNumber`** (integer): For `listingUrls` and `keywords`, this is the page number to start scraping from.

- **`finalPageNumber`** (integer): The final page number to scrape. If both `startPageNumber` and `finalPageNumber` are `0`, the scraper will attempt to scrape all available pages.

### Output

The scraper returns a dataset where each item is a detailed JSON object representing a single product. The data is highly structured, linking variants to their specific media (images) and pricing. You get a complete picture of the product, from its top-level description and features to the granular details of each available option.

#### Sample Output Record

Here is an example of the rich data object you can expect for each product:

```json
{
    "URL": "https://www.costco.com/p/-/anihana-shower-steamers-176-oz-12-pack/4000340933",
    "idCodes": {
        "SKU": ["1913994", "1914000"],
        "modelNumber": "",
        "productId": "4000340933"
    },
    "seller": {
        "brand": "anihana",
        "brandURL": "https://www.costco.com/s?keyword=anihana&refine=||Brand_attr-anihana"
    },
    "title": "anihana Shower Steamers, 1.76 oz, 12-pack",
    "media": [
        {
            "url": "https://cdn.bfldr.com/U447IH35/as/pxg72bhg8h7mpfq538jscm6b/4000340933-847_relaxandrefresh_1?auto=webp&format=jpg",
            "order": "1",
            "type": "",
            "assignedVariantsSKU": ["1913994"]
        },
        {
            "url": "https://cdn.bfldr.com/U447IH35/as/rh5476zjhhjtvhq589f35s/4000340933-847_relaxandrefresh_3?auto=webp&format=jpg",
            "order": "3",
            "type": "",
            "assignedVariantsSKU": ["1913994"]
        },
        {
            "url": "https://cdn.bfldr.com/U447IH35/as/xjf9xnv8b9zmq9vkns577xc/4000340933-847_relaxandrefresh_5?auto=webp&format=jpg",
            "order": "5",
            "type": "",
            "assignedVariantsSKU": ["1913994"]
        },
        {
            "url": "https://cdn.bfldr.com/U447IH35/as/4jn3gvgzwh3jsbgcns4vtzjn/4000340933-847_sweetandserene_1?auto=webp&format=jpg",
            "order": "1",
            "type": "",
            "assignedVariantsSKU": ["1914000"]
        },
        {
            "url": "https://cdn.bfldr.com/U447IH35/as/73mtksrmg97nknnrh92mrps/4000340933-847_sweetandserene_3?auto=webp&format=jpg",
            "order": "3",
            "type": "",
            "assignedVariantsSKU": ["1914000"]
        },
        {
            "url": "https://cdn.bfldr.com/U447IH35/as/sbxmv3gpxpmrcb98xxrvp6/4000340933-847_sweetandserene_4?auto=webp&format=jpg",
            "order": "4",
            "type": "",
            "assignedVariantsSKU": ["1914000"]
        }
    ],
    "pricing": {
        "salePrice": 24.99,
        "fullPrice": 34.99,
        "currencySymbol": "USD"
    },
    "isAvailable": true,
    "rating": {
        "itemRating": 2.6,
        "itemReviews": 5
    },
    "category": {
        "fullPath": "Home > Beauty > Bath & Body",
        "pathParts": [
            {
                "name": "Home",
                "url": "https://www.costco.com/"
            },
            {
                "name": "Beauty",
                "url": "https://www.costco.com/beauty.html"
            },
            {
                "name": "Bath & Body",
                "url": "https://www.costco.com/bath-body.html"
            }
        ]
    },
    "info": {
        "features": [
            "Crafted in New Zealand",
            "100% Clean & Safe Ingredients",
            "Essential Oil Aromatherapy for your Shower Experience",
            "Dissolve in the Shower for Spa-Like Experience",
            "Vibrant, Uplifting Scents Help You Feel Rejuvenated"
        ],
        "descriptionHtml": "<div class=\"MuiAccordionDetails-root mui-llc21o\"><div style=\"max-height:1200px;overflow:hidden\"><div><div id=\"product-details-summary\" class=\"mui-1cy54mi\"><span style=\"font-size: 0.875rem; font-family: inherit;\"><strong>Limit 5 Per Membership</strong><br aria-hidden=\"true\">\n<br aria-hidden=\"true\">\nEnjoy soothing, rejuvenating showers with the relaxing and refreshing essential oils released by these twelve high-quality shower steamers. Turning shower time into a luxurious spa-like experience, Anihana Shower Steamers are known for their transformative scents. Delivering joy in every pack, Anihana strive for sustainability at every step and want everyone to enjoy those simple everyday moments of relaxation and bliss that are crucial to wellbeing. Share the love; this 12-pack includes 12 individually packaged shower steamers, making this a great collection to use for gifts for those special people in your life.<br aria-hidden=\"true\">\n<br aria-hidden=\"true\">\n<strong>Includes:<br aria-hidden=\"true\">\n<br aria-hidden=\"true\">\nSweet &amp; Serene Set:</strong></span>\n<ul>\n\t<li><span style=\"font-size: 0.875rem; font-family: inherit;\">6 x Anihana Berry Ripple Shower Steamers</span></li>\n\t<li><span style=\"font-size: 0.875rem; font-family: inherit;\">6 x Anihana Floral Fantasy Shower Steamers</span></li>\n</ul>\n<br aria-hidden=\"true\">\n<span style=\"font-size: 0.875rem; font-family: inherit;\"><strong>Relax &amp; Refresh Set:</strong></span>\n\n<ul>\n\t<li><span style=\"font-size: 0.875rem; font-family: inherit;\">6 x Anihana Mint Refresher Shower Steamers</span></li>\n\t<li><span style=\"font-size: 0.875rem; font-family: inherit;\">6 x Anihana Lavender Love Shower Steamers</span></li>\n</ul>\n<br aria-hidden=\"true\">\n<span style=\"font-size: 0.875rem; font-family: inherit;\"><strong>How to use:</strong><br aria-hidden=\"true\">\nPlace a shower steamer colored side up in a corner of the shower floor, away from direct water flow, but where water on the floor will still reach it. The water will slowly dissolve the shower steamer, releasing the scent into the shower steam. Breathe in and enjoy the scents released from the shower steamer as it slowly dissolves. Note that using other scented products such as soap or shampoo may diminish the aromatherapy experience.<br aria-hidden=\"true\">\n<br aria-hidden=\"true\">\n<strong>Care and safety:</strong> Store in a cool, dry place. Not for use in bath. Do not ingest. Rinse shower floor after use to prevent slipping.<br aria-hidden=\"true\">\n<br aria-hidden=\"true\">\n<strong>Ingredients:</strong><br aria-hidden=\"true\">\n<br aria-hidden=\"true\">\n<strong>Anihana Berry Ripple Shower Steamer:</strong> Sodium Bicarbonate, Citric Acid, Parfum (Phthalate free), Mica (ethically sourced), Titanium Dioxide, Iron Oxides.<br aria-WELCOME-TO-THE-LAST-GAME-hidden=\"true\">\n<br aria-hidden=\"true\">\n<strong>Anihana Floral Fantasy Shower Steamer:</strong> Sodium Bicarbonate, Citric Acid, Parfum (Phthalate free), Synthetic Fluorphlogopite, Titanium Dioxide, CI 75470, Tin Oxide.<br aria-hidden=\"true\">\n<br aria-hidden=\"true\">\n<strong>Anihana Mint Refresher Shower Steamer:</strong> Sodium Bicarbonate, Citric Acid, Fragrance (Phthalate free), Mentha Piperita (Peppermint) Oil, Eucalyptus Globulous Leaf Oil, Water (Aqua), Mica (ethically sourced), Alcohol.<br aria-hidden=\"true\">\n<br aria-hidden=\"true\">\n<strong>Anihana Lavender Love Shower Steamer:</strong> Sodium Bicarbonate, Citric Acid, Fragrance (Phthalate free), Lavandula Angustifolia (Lavender) Flower Oil, Water (Aqua), Mica (ethically sourced), Alcohol.</span></div></div></div></div>",
        "specifications": [
            {
                "attribute": "Brand",
                "value": "anihana"
            },
            {
                "attribute": "Container Size",
                "value": "1.76 oz"
            },
            {
                "attribute": "Number of Pieces",
                "value": "12 Pack"
            },
            {
                "attribute": "Online Only",
                "value": "Online Only"
            }
        ]
    },
    "variants": [
        {
            "primarySKU": "1913994",
            "SKU": "1913994",
            "options": [
                {
                    "attribute": "Scent",
                    "value": "Relax u0026 Refresh"
                }
            ],
            "pricing": {
                "salePrice": 24.99,
                "fullPrice": 34.99,
                "currencySymbol": "USD"
            },
            "isAvailableOnWarehouse": true,
            "isAvailableOnWebsite": true
        },
        {
            "primarySKU": "1914000",
            "SKU": "1914000",
            "options": [
                {
                    "attribute": "Scent",
                    "value": "Sweet u0026 Serene"
                }
            ],
            "pricing": {
                "salePrice": 24.99,
                "fullPrice": 34.99,
                "currencySymbol": "USD"
            },
            "isAvailableOnWarehouse": true,
            "isAvailableOnWebsite": true
        }
    ]
}
```

### Usage

Provide your input configuration and run the actor. The results will be collected in the default dataset.

### Data Export

You can download the scraped data in various formats, including JSON, CSV, and Excel, from the Apify platform.

# Actor input Schema

## `productUrls` (type: `array`):

This is a list of product URLs.

## `listingUrls` (type: `array`):

This is a list of category URLs

## `keywords` (type: `array`):

This is a list of keyword to search products based on.

## `startPageNumber` (type: `integer`):

Page number to start scraping products.

## `finalPageNumber` (type: `integer`):

Page number to start scraping products.

## `useApifyProxy` (type: `boolean`):

if enabled use the Apify Proxy, when disabled use the IP of the current container.

## Actor input object example

```json
{
  "productUrls": [
    "https://www.costco.com/p/-/anihana-shower-steamers-176-oz-12-pack/4000340933"
  ],
  "startPageNumber": 0,
  "finalPageNumber": 0,
  "useApifyProxy": true
}
```

# Actor output Schema

## `overview` (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 = {
    "productUrls": [
        "https://www.costco.com/p/-/anihana-shower-steamers-176-oz-12-pack/4000340933"
    ],
    "startPageNumber": 0,
    "finalPageNumber": 0
};

// Run the Actor and wait for it to finish
const run = await client.actor("eneiromatos/ultimate-costco-com-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 = {
    "productUrls": ["https://www.costco.com/p/-/anihana-shower-steamers-176-oz-12-pack/4000340933"],
    "startPageNumber": 0,
    "finalPageNumber": 0,
}

# Run the Actor and wait for it to finish
run = client.actor("eneiromatos/ultimate-costco-com-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 '{
  "productUrls": [
    "https://www.costco.com/p/-/anihana-shower-steamers-176-oz-12-pack/4000340933"
  ],
  "startPageNumber": 0,
  "finalPageNumber": 0
}' |
apify call eneiromatos/ultimate-costco-com-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,eneiromatos/ultimate-costco-com-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/Ql4F5kK80o2QCBh74/builds/RcbbIif5ucbSFphNg/openapi.json
