# Mudah.my Scraper - Malaysia Classifieds (`lewxiangang/mudah-search-scraper`) Actor

Scrape Mudah.my marketplace listings including prices, locations, and seller details. Search by keyword, category, and location for Malaysian classifieds.

- **URL**: https://apify.com/lewxiangang/mudah-search-scraper.md
- **Developed by:** [lewxiangang](https://apify.com/lewxiangang) (community)
- **Categories:** E-commerce
- **Stats:** 19 total users, 3 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

from $1.00 / 1,000 results

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/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

Scrape listings from **Mudah.my**, Malaysia's largest online classifieds marketplace with 1.6M+ active listings and 7.63M monthly visits. Extract car prices, property listings, electronics deals, job postings, and more — structured and ready for analysis.

### What data does this actor extract?

This Apify Actor automatically scrapes Mudah.my search results and listing pages. It extracts:

- **Listing details**: title, price (MYR), description, images
- **Location data**: city/area, state
- **Category info**: category, subcategory, condition (new/used)
- **Seller info**: individual vs. dealer (no personal data collected)
- **Category-specific attributes**: make, model, year, mileage (cars); bedrooms, sqft (property); etc.

#### Supported categories

Cars for Sale, Properties for Sale/Rent, Motorcycles, Jobs, Electronics, Mobile Phones, Home Appliances, Computers, Fashion, Sports, Baby & Kids, Music Instruments, Pets, Services.

#### Supported locations

All Malaysian states: Kuala Lumpur, Selangor, Johor, Penang, Perak, Sabah, Sarawak, Kedah, Kelantan, Melaka, Negeri Sembilan, Pahang, Perlis, Terengganu, Putrajaya, Labuan — or nationwide.

### Input example

```json
{
  "category": "cars-for-sale",
  "location": "selangor",
  "priceMin": 20000,
  "priceMax": 80000,
  "maxResults": 50,
  "sortBy": "newest",
  "includeDetails": false,
  "proxy": {
    "useApifyProxy": true,
    "apifyProxyGroups": ["RESIDENTIAL"]
  }
}
```

Or provide direct URLs:

```json
{
  "startUrls": [
    { "url": "https://www.mudah.my/selangor/cars-for-sale/toyota" }
  ],
  "maxResults": 200,
  "includeDetails": true
}
```

### Output example

```json
{
  "id": "123456789",
  "title": "2022 Toyota Vios 1.5 E Auto",
  "price": 68000,
  "currency": "MYR",
  "location": "Petaling Jaya",
  "state": "Selangor",
  "category": "Cars for Sale",
  "subcategory": "Toyota",
  "condition": "used",
  "sellerType": "dealer",
  "description": "Well maintained. Full service record. Low mileage...",
  "images": [
    "https://img.mudah.my/photos/123456789_1.jpg",
    "https://img.mudah.my/photos/123456789_2.jpg"
  ],
  "listingUrl": "https://www.mudah.my/2022-toyota-vios-1-5-e-auto-123456789.htm",
  "postedAt": "2026-03-08T10:30:00.000Z",
  "attributes": {
    "make": "Toyota",
    "model": "Vios",
    "year": "2022",
    "mileage": "35000",
    "transmission": "Automatic",
    "fuel_type": "Petrol",
    "engine_capacity": "1500"
  },
  "scrapedAt": "2026-03-09T14:22:00.000Z"
}
```

### Use cases

- **Car dealers**: Monitor competitor pricing across Malaysia, track market trends for specific makes/models
- **Property agents**: Aggregate rental and sale listings by area, analyze pricing per sqft
- **Market researchers**: Track consumer electronics pricing, identify demand patterns
- **E-commerce sellers**: Find underpriced items for resale arbitrage
- **Data journalists**: Analyze the Malaysian secondhand market

### How it works

1. **Playwright browser automation** — renders pages like a real browser to bypass Mudah.my's WAF
2. **API interception** — automatically detects and uses internal JSON API endpoints when available (faster than DOM scraping)
3. **DOM fallback** — robust multi-selector scraping when API is unavailable
4. **Automatic pagination** — follows search result pages until `maxResults` is reached
5. **Stealth mode** — randomized viewports, user agents, delays, and anti-detection scripts

### Configuration options

| Parameter | Type | Default | Description |
|-----------|------|---------|-------------|
| `startUrls` | array | `[]` | Direct Mudah.my URLs to scrape |
| `searchQuery` | string | — | Keyword search (e.g., "Toyota Vios") |
| `location` | string | `malaysia` | State/city slug |
| `category` | string | — | Category slug |
| `priceMin` | number | — | Minimum price filter (MYR) |
| `priceMax` | number | — | Maximum price filter (MYR) |
| `maxResults` | number | `100` | Max listings to extract |
| `sortBy` | string | — | `newest`, `price_asc`, or `price_desc` |
| `includeDetails` | boolean | `false` | Visit each listing page for full data |
| `proxy` | object | — | Proxy configuration |

### Pricing

This actor costs approximately **$1.00 per 1,000 results** plus Apify platform usage fees.

| Scenario | Results | Est. CUs | Est. Time | Est. Cost |
|----------|---------|----------|-----------|-----------|
| 50 listings (search only) | 50 | ~0.03 | 1-2 min | ~$0.05 |
| 100 listings (search only) | 100 | ~0.05 | 2-3 min | ~$0.10 |
| 100 listings (with details) | 100 | ~0.30 | 8-12 min | ~$0.10 |
| 500 listings (search only) | 500 | ~0.20 | 8-10 min | ~$0.50 |
| 1,000 listings (search only) | 1,000 | ~0.40 | 15-20 min | ~$1.00 |
| 1,000 listings (with details) | 1,000 | ~2.50 | 60-90 min | ~$1.00 |

Costs depend on proxy type and Mudah.my response times. Residential proxies recommended.

### Tips for best results

- **Use residential proxies** — Mudah.my blocks datacenter IPs aggressively
- **Start with `includeDetails: false`** — much faster; only enable if you need full descriptions and all images
- **Use `startUrls` for brand-specific searches** — e.g., `https://www.mudah.my/malaysia/cars-for-sale/toyota`
- **Keep `maxResults` reasonable** — larger runs cost more CUs and take longer

### Integrations

Connect this actor to your existing workflows and tools:

- **API access** — call the actor programmatically via Apify REST API or client libraries (JavaScript, Python)
- **Webhooks** — get notified when a run finishes and trigger downstream processing
- **Zapier** — connect Mudah.my data to 5,000+ apps via the Apify Zapier integration
- **Google Sheets** — export results directly to a spreadsheet for easy sharing and analysis
- **Make.com** (formerly Integromat) — build automated workflows with Mudah.my data as a trigger or data source
- **n8n** — use the Apify node in n8n to integrate scraping into self-hosted automation pipelines

### FAQ

**Does this work with all Mudah.my categories?**
Yes, all 15 categories are supported including Cars, Properties, Electronics, Jobs, Fashion, Pets, and more.

**What proxies should I use?**
Residential proxies are recommended. Mudah.my actively blocks datacenter IPs, so residential or mobile proxies give the best success rate.

**Can I export to CSV/Excel?**
Yes. You can export results to CSV, JSON, Excel, or other formats directly from the Apify console or via the API.

**Is personal data collected?**
No. Phone numbers and email addresses are automatically redacted from scraped data. The actor is designed to be PDPA compliant.

### Limitations

- Mudah.my may show CAPTCHAs on heavy usage; residential proxies reduce this
- Some listing details (full image galleries, seller history) require `includeDetails: true`
- Very old or removed listings may return 404
- Rate-limited to avoid overloading the target site

### Is scraping Mudah.my legal?

This actor is designed to comply with Malaysia's **Personal Data Protection Act 2010 (PDPA)**:

- **Phone numbers, WhatsApp contacts, and email addresses are automatically redacted** from scraped data
- Only publicly visible listing information is collected (prices, specs, locations, photos)
- No login or authentication is used — only public pages are scraped

**Important**: Users are responsible for ensuring their use of scraped data complies with applicable laws and Mudah.my's Terms of Service. This actor is intended for legitimate market research, price comparison, and data analysis purposes only. The developer assumes no liability for misuse.

### Related actors

Need Malaysian stock market data? Check out [KLSE Fundamentals Scraper](https://apify.com/lewxiangang/klse-fundamentals) for quarterly results, dividends, and financial ratios of 1,000+ Bursa Malaysia stocks.

# Actor input Schema

## `startUrls` (type: `array`):

Direct Mudah.my category or search URLs to scrape. If provided, overrides location/category/searchQuery params.

## `searchQuery` (type: `string`):

Keyword to search for (e.g., 'Toyota Vios', 'iPhone 15'). Used when startUrls is empty.

## `location` (type: `string`):

State or city slug (e.g., 'kuala-lumpur', 'selangor', 'penang', 'malaysia' for nationwide).

## `category` (type: `string`):

Category slug to browse.

## `priceMin` (type: `integer`):

Filter listings with price >= this value.

## `priceMax` (type: `integer`):

Filter listings with price <= this value.

## `sortBy` (type: `string`):

Sort order for listings.

## `maxResults` (type: `integer`):

Maximum number of listings to scrape.

## `includeDetails` (type: `boolean`):

If true, visits each listing page to get full description, all images, and extra attributes. Slower but more data.

## `proxy` (type: `object`):

Proxy settings. Recommended: use Apify residential proxies for best results.

## Actor input object example

```json
{
  "startUrls": [
    {
      "url": "https://www.mudah.my/malaysia/cars-for-sale"
    }
  ],
  "searchQuery": "iPhone 15 Pro",
  "location": "malaysia",
  "sortBy": "newest",
  "maxResults": 100,
  "includeDetails": false,
  "proxy": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

# 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 = {
    "startUrls": [
        {
            "url": "https://www.mudah.my/malaysia/cars-for-sale"
        }
    ],
    "searchQuery": "Toyota Vios",
    "proxy": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ]
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("lewxiangang/mudah-search-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 = {
    "startUrls": [{ "url": "https://www.mudah.my/malaysia/cars-for-sale" }],
    "searchQuery": "Toyota Vios",
    "proxy": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
    },
}

# Run the Actor and wait for it to finish
run = client.actor("lewxiangang/mudah-search-scraper").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "startUrls": [
    {
      "url": "https://www.mudah.my/malaysia/cars-for-sale"
    }
  ],
  "searchQuery": "Toyota Vios",
  "proxy": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}' |
apify call lewxiangang/mudah-search-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=lewxiangang/mudah-search-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

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