Daraz.pk Scraper avatar
Daraz.pk Scraper

Pricing

Pay per usage

Go to Apify Store
Daraz.pk Scraper

Daraz.pk Scraper

Efficiently scrape product details, prices, and reviews from Daraz.pk, Pakistan's largest e-commerce platform. This lightweight actor ensures fast data extraction. For consistent results and to bypass anti-scraping measures, residential proxies are strongly recommended.

Pricing

Pay per usage

Rating

0.0

(0)

Developer

Shahid Irfan

Shahid Irfan

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

11 days ago

Last modified

Share

Daraz.pk Product Scraper

Extract comprehensive product data from Daraz.pk, Pakistan's leading e-commerce marketplace. This scraper employs intelligent dual-extraction methodology, prioritizing efficient JSON API calls with automatic HTML fallback for maximum reliability and performance.

Key Features

  • Intelligent Extraction – Automatically attempts JSON API extraction first, seamlessly falls back to HTML parsing if needed
  • Comprehensive Data – Captures titles, prices, discounts, ratings, reviews, brands, images, and product URLs
  • Advanced Filtering – Filter by price range, sort options, stock availability, and custom categories
  • Pagination Support – Automatically navigates through multiple pages to collect desired product count
  • High Performance – Optimized for speed with configurable concurrency and request limits
  • Proxy Support – Built-in Apify Proxy integration for reliable, uninterrupted scraping

Use Cases

  • Price Monitoring – Track product prices and discount trends over time
  • Market Research – Analyze product availability, pricing strategies, and market trends
  • Competitor Analysis – Compare products, prices, and ratings across categories
  • Inventory Tracking – Monitor stock availability for specific products or categories
  • Data Analytics – Build datasets for e-commerce insights and business intelligence

Input Configuration

ParameterTypeDescription
Category URLStringDaraz.pk category page URL (e.g., https://www.daraz.pk/womens-fashion/)
Search QueryStringProduct search keywords (e.g., "iPhone 15", "dress", "laptop"). Creates standard Daraz.pk catalog URL
Multiple Start URLsStringList of Daraz.pk URLs to scrape from (one URL per line). Highest priority - overrides other URL options

Limits & Performance

ParameterTypeDefaultDescription
Maximum ProductsInteger100Maximum number of products to scrape (0 = unlimited)
Maximum PagesInteger50Safety limit on pagination depth

Filtering & Sorting

ParameterTypeDescription
Minimum PriceNumberFilter products by minimum price in PKR
Maximum PriceNumberFilter products by maximum price in PKR
Sort BySelectOptions: Popularity, Price (Low/High), Newest, Top Rated
Include Out of StockBooleanInclude products currently unavailable (default: false)

Proxy Configuration

ParameterTypeDescription
Proxy ConfigurationObjectApify Proxy settings - Residential proxies recommended for optimal results

Output Format

Each scraped product contains the following structured data:

{
"productId": "123456789",
"title": "Women Summer Dress - Floral Print",
"brand": "Fashion Brand",
"price": "Rs. 1,299",
"originalPrice": "Rs. 2,500",
"discount": "48% OFF",
"rating": 4.5,
"reviewCount": 127,
"imageUrl": "https://static-01.daraz.pk/p/image.jpg",
"productUrl": "https://www.daraz.pk/products/...",
"inStock": true,
"sellerName": "Official Store",
"location": "Lahore",
"categoryName": "Women's Fashion",
"scrapedAt": "2025-12-26T10:30:00.000Z",
"source": "api"
}

Field Descriptions

FieldTypeDescription
productIdStringUnique Daraz product identifier
titleStringProduct name and description
brandStringBrand or manufacturer name
priceStringCurrent selling price in PKR
originalPriceStringOriginal price before discount
discountStringDiscount percentage or amount
ratingNumberAverage customer rating (0-5)
reviewCountNumberTotal number of customer reviews
imageUrlStringPrimary product image URL
productUrlStringDirect link to product page
inStockBooleanStock availability status
sellerNameStringMerchant or seller name
locationStringSeller location
categoryNameStringProduct category
scrapedAtStringISO timestamp of data extraction
sourceStringExtraction method: "api" or "html"

Quick Start Examples

Example 1: Scrape Women's Fashion Category

{
"categoryUrl": "https://www.daraz.pk/womens-fashion/",
"maxProducts": 100,
"sortBy": "popularity"
}

Example 2: Search for Specific Products

{
"searchQuery": "iPhone 15 Pro Max",
"maxProducts": 50,
"sortBy": "priceasc",
"minPrice": 200000,
"maxPrice": 300000
}

Example 3: Multiple Categories

{
"startUrls": "https://www.daraz.pk/mens-fashion/\nhttps://www.daraz.pk/womens-fashion/\nhttps://www.daraz.pk/electronic-devices/",
"maxProducts": 200,
"includeOutOfStock": true
}

Note: Use the textarea editor to easily add multiple URLs, one per line.

Example 4: Price Range Filter

{
"categoryUrl": "https://www.daraz.pk/laptops/",
"minPrice": 50000,
"maxPrice": 100000,
"sortBy": "rating",
"maxProducts": 100
}

Technical Specifications

Extraction Methodology

  1. Primary Method: JSON API
    • Sends AJAX requests to Daraz.pk internal API endpoints
    • Parses structured JSON responses for maximum accuracy
    • Significantly faster than HTML parsing
    • Provides complete product metadata
  2. Fallback Method: HTML Parsing
    • Activates automatically when API extraction fails
    • Uses CSS selectors to extract product information
    • Ensures continuous operation under varying conditions
    • Maintains data consistency across methods

Performance Characteristics

  • Concurrency – 5 parallel requests for optimal balance
  • Request Timeout – 90 seconds per request
  • Retry Strategy – 3 automatic retries with exponential backoff
  • Session Management – Cookie-based session handling for consistency
  • Deduplication – Built-in URL deduplication prevents duplicate entries

System Requirements

  • Node.js Version – 22 or higher
  • Memory – Minimum 512MB recommended
  • Proxy – Apify Residential Proxy recommended for enterprise use

Best Practices

Optimal Configuration

  • Use Residential Proxies for large-scale scraping to avoid rate limits
  • Set realistic maxProducts limits based on your data needs
  • Enable includeOutOfStock: false for active inventory only
  • Use price filters to narrow results and improve efficiency

Rate Limiting

  • Default concurrency (5) balances speed and server load
  • Automatic session pooling prevents IP-based blocking
  • Built-in retry logic handles temporary failures gracefully

Data Quality

  • JSON API extraction provides highest data accuracy
  • HTML fallback ensures completeness when API unavailable
  • Timestamps enable temporal analysis of price changes
  • Source field identifies extraction method for quality control

Common Issues & Solutions

Output Integration

Export Formats

Results can be exported in multiple formats:

  • JSON – Structured data for programmatic access
  • CSV – Spreadsheet compatibility for analysis
  • Excel – Direct import to Microsoft Excel
  • XML – Legacy system integration
  • RSS – Feed-based consumption

API Access

  • Access scraped data via Apify API endpoints
  • Real-time data retrieval during scraping
  • Webhook integration for automated workflows
  • Scheduled runs for periodic data collection

Pricing & Credits

This scraper consumes Apify platform credits based on:

  • Compute Units – Processing time and memory usage
  • Proxy Usage – Residential proxy data transfer costs
  • Storage – Dataset storage duration and size

Typical consumption: ~0.01-0.05 compute units per 100 products (without proxy)

Support & Resources

  • Scraping publicly available product data for personal or business intelligence purposes
  • Users responsible for compliance with Daraz.pk Terms of Service
  • Respect rate limits and avoid excessive requests
  • Do not scrape personal or sensitive information
  • Intended for legitimate market research and price monitoring

Version History

  • 1.0.0 – Initial release with dual extraction methodology

Built for Apify Platform
Professional web scraping and automation solutions