DEV Community

wfgsss
wfgsss

Posted on

How to Compare Wholesale Prices Across Made-in-China, DHgate, and Yiwugo Using Data

When sourcing products from China, the biggest challenge isn't finding suppliers — it's knowing which platform offers the best deal for your specific product.

Made-in-China.com, DHgate, and Yiwugo each serve different market segments. Running scrapers across all three and comparing the results gives you a data-driven edge that manual browsing simply can't match.

In this tutorial, I'll show you how to scrape the same product category from all three platforms, merge the data, and build a comparison analysis.

Why Cross-Platform Comparison Matters

Each platform has different strengths:

  • Yiwugo: Small commodities, lowest MOQs, Yiwu market prices
  • DHgate: Consumer electronics, fashion, dropshipping-friendly
  • Made-in-China.com: Industrial/B2B products, verified manufacturers

A product that's cheapest on DHgate might have a lower MOQ on Yiwugo, or a more reliable supplier on Made-in-China.com. Without data from all three, you're making decisions with incomplete information.

Step 1: Set Up the Three Scrapers

We'll use the Apify platform to run all three scrapers. Install the Apify client first:

pip install apify-client
Enter fullscreen mode Exit fullscreen mode

Here's the configuration for each scraper:

from apify_client import ApifyClient
import json
import time

client = ApifyClient("YOUR_APIFY_TOKEN")

# Define the search keyword
KEYWORD = "led strip lights"

# Scraper configurations
SCRAPERS = {
    "yiwugo": {
        "actor_id": "jungle_intertwining/yiwugo-scraper",
        "input": {
            "keyword": KEYWORD,
            "maxItems": 50
        }
    },
    "dhgate": {
        "actor_id": "jungle_intertwining/dhgate-scraper",
        "input": {
            "keyword": KEYWORD,
            "maxItems": 50
        }
    },
    "made_in_china": {
        "actor_id": "jungle_intertwining/made-in-china-scraper",
        "input": {
            "keyword": KEYWORD,
            "maxItems": 50
        }
    }
}
Enter fullscreen mode Exit fullscreen mode

Step 2: Run All Three Scrapers

Run them sequentially and collect results:

def run_scraper(name, config):
    """Run a single scraper and return results."""
    print(f"Running {name} scraper...")
    run = client.actor(config["actor_id"]).call(run_input=config["input"])

    items = []
    for item in client.dataset(run["defaultDatasetId"]).iterate_items():
        item["_source"] = name
        items.append(item)

    print(f"  {name}: {len(items)} products found")
    return items

# Collect all results
all_products = []
for name, config in SCRAPERS.items():
    products = run_scraper(name, config)
    all_products.extend(products)
    time.sleep(2)  # Brief pause between runs

print(f"\nTotal: {len(all_products)} products from 3 platforms")
Enter fullscreen mode Exit fullscreen mode

Step 3: NoData

Each platform returns data in a different format. We need to normalize it into a common structure:

def normalize_product(item):
    """Convert platform-specific data to a common format."""
    source = item.get("_source", "unknown")

    if source == "yiwugo":
        return {
            "source": "Yiwugo",
            "title": item.get("title", ""),
            "price_min": item.get("priceMin"),
            "price_max": item.get("priceMax"),
            "currency": item.get("currency", "CNY"),
            "moq": item.get("minOrder"),
            "supplier": item.get("shopName", ""),
           em.get("url", "")
        }
    elif source == "dhgate":
        return {
            "source": "DHgate",
            "title": item.get("title", ""),
            "price_min": item.get("priceMin"),
            "price_max": item.get("priceMax"),
            "currency": "USD",
            "moq": item.get("minOrder", 1),
            "supplier": item.get("sellerName", ""),
            "url": item.get("url", "")
        }
    elif source == "made_in_china":
        return {
            "source": "Made-in-China",
            "title": item.get("title", ""),
            "price_min": item.get("priceMin"),
            "price_max": item.get("priceMax"),
            "currency": "USD",
            "moq": item.get("moq"),
            "supplier": item.get("supplierName", ""),
            "url": item.get("url", "")
        }

    return None

# Normalize all products
normalized = []
for item in all_products:
    product = normalize_product(item)
    if product:
        normalized.append(product)

print(f"Normalized {len(normalized)} products")
Enter fullscreen mode Exit fullscreen mode

Step 4: Convert Currencies for Fair Comparison

Yiwugo prices are in CNY while DHgate and Made-in-China use USD.d a common currency:
thon

Approximate CNY to USD rate (update as needed)

CNY_TO_USD = 0.14

def to_usd(price, currency):
"""Convert price to USD."""
if price is None:
return None
if currency == "CNY":
return round(price * CNY_TO_USD, 2)
return price

Add USD prices to all products

for product in normalized:
product["price_min_usd"] = to_usd(product["price_min"], product["currency"])
product["price_max_usd"] = to_usd(product["price_max"], product["currency"])


## Step 5: Build the Comparison Analysis

Now let's analyze the data across platforms:

Enter fullscreen mode Exit fullscreen mode


python
import statistics
latform_summary(products, platform_name):
"""Generate summary statistics for a platform."""
platform_products = [p for p in products if p["source"] == platform_name]

if not platform_products:
    return None

prices = [p["price_min_usd"] for p in platform_products if p["price_min_usd"]]
moqs = [p["moq"] for p in platform_products if p["moq"]]

return {
    "platform": platform_name,
    "product_count": len(platform_products),
    "avg_price": round(statistics.mean(prices), 2) if prices else None,
    "min_price": min(prices) if prices else None,
    "max_price": max(prices) if prices else None,
    "median_price": round(statistics.median(prices), 2) if prices else None,
    "avg_moq": round(statistics.mean(moqs)) if moqs else None,
    "min_moq": min(moqs) if moqs else None,
}
Enter fullscreen mode Exit fullscreen mode

Generate summaries

platforms = ["Yiwugo", "DHgate", "Made-in-China"]
summaries = []

for platform in platforms:
summary = platform_summary(normalized, platform)
if summary:
summaries.append(summary)
print(f"\n--- {platform} ---")
print(f" Products found: {summary['product_count']}")
print(f" Price range: ${summary['min_price']} - ${summary['max_price']}")
print(f" Average price: ${summary['avg_price']}")
print(f" Median price: ${summary['median_price']}")
print(f" Average MOQ: {summary['avg_moq']}")
print(f" Lowest MOQ: {summary['min_moq']}")


## Step 6: Find the Best Deals

The most useful output is a ranked list of the cheapest options across all platforms:

Enter fullscreen mode Exit fullscreen mode


python
def find_best_deals(products, top_n=10):
"""Find the cheapest products across all platforms."""
# Filter products with valid prices
priced = [p for p in products if p["price_min_usd"] is not None]

# Sort by minimum price
priced.sort(key=lambda x: x["price_min_usd"])

print(f"\n{'='*70}")
print(f"TOP {top_n} CHEAPEST OPTIONS ACROSS ALL PLATFORMS")
print(f"{'='*70}")

for i, product in enumerate(priced[:top_n], 1):
    moq_str = f"MOQ: {product['moq']}" if product["moq"] else "MOQ: N/A"
    print(f"\n{i}. [{product['source']}] ${product['price_min_usd']}")
    print(f"   {product['title'][:60]}...")
    print(f"   Supplier: {product['supplier'][:40]}")
    print(f"   {moq_str}")

return priced[:top_n]
Enter fullscreen mode Exit fullscreen mode

best_deals = find_best_deals(normalized)


## Step 7: Export to CSV for Further Analysis

Save the comparison data for use in spreadsheets or BI tools:

Enter fullscreen mode Exit fullscreen mode


python
import csv

def export_comparison(products, filename="cross_platform_comparison.csv"):
"""Export normalized data to CSV."""
fields = [
"source", "title", "price_min_usd", "price_max_usd",
"currency", "moq", "supplier", "url"
]

with open(filename, "w", newline="", encoding="utf-8") as f:
    writer = csv.DictWriter(f, fieldnames=fields)
    writer.writeheader()
    for product in products:
        writer.writerow({kt.get(k) for k in fields})

print(f"\nExported {len(products)} products to {filename}")
Enter fullscreen mode Exit fullscreen mode

export_comparison(normalized)


## Real-World Example: LED Strip Lights

Here's what a typical comparison looks like for "LED strip lights":

**Yiwugo** (Yiwu market prices):
- Average price: $0.42/meter
- MOQ: 100 meters typical
- Best for: Bulk orders, lowest unit cost
- Suppliers: Yiwu-based manufacturers and traders

**DHgate** (Consumer/dropshipping):
- Average price: $1.85/meter
- MOQ: 1 piece (dropshipping-friendly)
- Best for: Small orders, testing products
- Suppliers: Mix of manufacturers and resellers

**Made-in-China.com** (B2B/industrial):
- Average price: $0.68/meter
- MOQ: 500 meters typical
- Best for: Large B2B orders, verified manufacturers
- Suppliers: Factory-direct with certifications

## When to Use Which Platform

Based on analyzing thousands of products across these three platforms:

**Choose Yiwugo when:**
- You need small commodities (accessories, toys, hld items)
- You want the lowest possible unit price
- You can handle CNY payments and Yiwu logistics

**Choose DHgate when:**
- You're dropshipping or testw product
- You need buyer protection and escrow
- Order quantities are small (1-100 units)

**Choose Made-in-China.com when:**
- You need industrial or B2B products
- Supplier verification matters (ISO, factory audits)
- Order volume justifies higher MOQs

## Automating the Comparison

For ongoing price monitoring, schedule this comparison to run weekly:

Enter fullscreen mode Exit fullscreen mode


python

Schedule with cron or Apify Scheduler

Run every Monday at 9 AM

Compare results with previous week's data

def weekly_comparison(keyword, history_file="price_history.json"):
"""Run weekly comparison and track price changes."""
import datetime

# Run scrapers
all_products = []
for name, config in SCRAPERS.items():
    config["input"]["keyword"] = keyword
    products = run_scraper(name, config)
    all_products.extend(products)

# Normalize and analyze
normalized = [normalize_product(p) for p in all_products]
normalized = [p for p in normalized if p]
Enter fullscreen mode Exit fullscreen mode

# Save snapshot
snapshot = {
"date": datetime.date.today().isoformat(),
"keyword": keyword,
"summaries": [platform_summary(normalized, p) for p in platforms],
"total_products": len(normalized)
}

# Load history and append
try:
    with open(history_file) as f:
        history = json.load(f)
except FileNotFoundError:
    history = []

history.append(snapshot)

with open(history_file, "w") as f:
    json.dump(history, f, indent=2)

return snapshot
Enter fullscreen mode Exit fullscreen mode



## Conclusion

Cross-platform price comparison turns sourcing from guesswork into a data-driven process. By scraping Yiwugo, DHgate, and Made-in-China.com simultaneously, you can:

1. Find the absolute lowest price for any product category
2. Compare MOQs to match your order size
3. Identify the most reliable suppliers across platforms
4. Track price trends over time

The complete code in this tutorial works with three Apify scrapers that handle all the complexity of scraping these platforms — anti-bot measures, pagination, and data extraction.

---

**Try the scrapers yourself:**

- [Yiwugo Scraper](https://apify.com/jungle_intertwining/yiwugo-screr) — Yiwu market product data
- [DHgate Scraper](https://apify.com/jungle_intertwining/dhgate-scraper) — DHgate product and seller data
- [Made-in-China Scraper](https://apify.com/jungle_intertwining/made-in-china-scraper) — B2B supplier and product data
- [China Wholesale Scraper Toolkit](https://github.com/wfgsss/china-wholesale-scraper-toolkit) — All three tools in one repo

**Related articles:**

- [How to Build a China Wholesale Price Tracker](https://dev.to/wfgsss/how-to-build-a-china-wholesale-price-tracker-with-dhgate-and-yiwugo-data-1dea)
- [Made-in-China.com vs DHgate vs Yiwugo: Which Platform to Scrape](https://dev.to/wfgsss/made-in-chinacom-vs-dhgate-vs-yiwugo-which-platfo-to-scrape-for-wholesale-product-data-42d9)
- [How to Automate B2B Supplier Screening](https://dev.to/wfgsss/how-to-automate-b2b-supplier-screening-with-made-in-chinacom-data-1ih1)
- [5 Ways to Use Made-in-China.com Data for Import Decisions](https://dev.to/wfgsss/5-ways-to-use-made-in-chinacom-data-for-import-business-decisions-3ij1)
- [The Complete Guide to China Wholesale Data Scraping](https://dev.to/wfgsss/the-complete-guide-to-china-wholesale-data-scraping-tools-platforms-and-best-practices-7n3)
Enter fullscreen mode Exit fullscreen mode

Top comments (0)