# IndiaMart Extractor (`gtgyani206/indiamart-scraper`) Actor

A Playwright-based Apify actor that extracts product listings from IndiaMART, including title, supplier, location, price, and links, and stores the data in a structured dataset for analysis or integration.

- **URL**: https://apify.com/gtgyani206/indiamart-scraper.md
- **Developed by:** [Gyanendra Thakur](https://apify.com/gtgyani206) (community)
- **Categories:** Automation, E-commerce
- **Stats:** 11 total users, 2 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $5.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/actors/running/actors-in-store.md#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

### What does IndiaMART Product Search Scraper do?

**IndiaMART Product Search Scraper** extracts structured product listings from [IndiaMART search results](https://dir.indiamart.com/). It is built for fast supplier discovery, B2B lead research, price checks, and recurring market monitoring from IndiaMART product search pages.

Give the Actor one or more IndiaMART search URLs, or enter product keywords such as `steel pipe`, `industrial valves`, or `packaging machine`. The Actor opens the rendered result pages, extracts product titles, supplier names, locations, price text, cleaned listing URLs, and crawl metadata, then saves everything to an Apify dataset. On Apify you can run it by API, schedule it, monitor it, export results, connect integrations, and use proxy rotation from the Input tab.

### Why use IndiaMART Product Search Scraper?

IndiaMART is a large B2B marketplace, but manual supplier research is slow and inconsistent. This Actor turns search result pages into a clean table that sourcing, sales, research, and operations teams can use immediately.

Common use cases include supplier lead generation, product availability checks, regional supplier discovery, price range monitoring, competitor research, sourcing list creation, and scheduled snapshots for internal dashboards. The default settings are intentionally small and fast so you can validate output quality before scaling to more searches or deeper pagination.

### How to use IndiaMART Product Search Scraper

1. Open the Actor and go to the **Input** tab.
2. Keep the default steel search URL for a quick test, or add your own IndiaMART search result URLs.
3. Optionally add `searchTerms` if you prefer entering product keywords instead of URLs.
4. Set `maxItems` and `maxPagesPerSearch` to control run size and cost.
5. Keep Apify Proxy enabled unless you have a reason to run without proxy.
6. Start the run and open the **Output** tab when it finishes.
7. Download the dataset as JSON, CSV, Excel, HTML, or connect it to your workflow through the Apify API.

Example input:

```json
{
  "startUrls": [
    { "url": "https://dir.indiamart.com/search.mp?ss=steel" }
  ],
  "searchTerms": ["stainless steel pipe", "industrial valves"],
  "maxItems": 20,
  "maxPagesPerSearch": 2,
  "maxConcurrency": 2,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

### Input

The Input tab exposes fast defaults plus controls for larger production runs.

- `startUrls`: IndiaMART search result URLs. The default and prefill use `https://dir.indiamart.com/search.mp?ss=steel`.
- `searchTerms`: Optional product keywords. Each keyword is converted into an IndiaMART search URL.
- `maxItems`: Maximum listings saved across all searches. Default is `20`.
- `maxPagesPerSearch`: Maximum pagination pages per search. Default is `2`.
- `maxConcurrency`: Browser pages processed in parallel. Default is `2` to balance speed and blocking risk.
- `maxRunTimeSeconds`: Wall-clock safety limit. Default is `270` seconds so runs can stop cleanly before common automated-test budgets.
- `includeSponsored`: Keep or skip cards that appear sponsored.
- `deduplicateResults`: Remove duplicates by cleaned link or product/supplier fallback.
- `minDelayMs` and `maxDelayMs`: Delay range between pages.
- `requestTimeoutSecs`: Navigation and selector timeout per page.
- `proxyConfiguration`: Proxy settings using Apify's proxy input editor. Apify Proxy is enabled by default.
- `debugMode`: Enables detailed extraction logs for troubleshooting.

### Output

Each dataset item represents one IndiaMART product listing card. You can download the dataset in various formats such as JSON, HTML, CSV, or Excel.

Example output:

```json
[
  {
    "title": "TMT Steel Bars",
    "company": "Example Steel Traders",
    "location": "Mumbai, Maharashtra",
    "price": "Rs 52,000 / Ton",
    "link": "https://dir.indiamart.com/impcat/tmt-steel-bars.html",
    "isSponsored": false,
    "extractionMode": "listing_card",
    "searchUrl": "https://dir.indiamart.com/search.mp?ss=steel",
    "pageNumber": 1,
    "position": 3,
    "scrapedAt": "2026-06-05T08:30:00.000Z",
    "source": "indiamart"
  }
]
```

### Data table

| Field | Type | Description |
| --- | --- | --- |
| `title` | string or null | Product or listing title |
| `company` | string or null | Supplier or company name |
| `location` | string or null | Supplier or listing location text |
| `price` | string or null | Visible IndiaMART price text |
| `link` | string or null | Cleaned IndiaMART listing URL |
| `isSponsored` | boolean or null | Whether the card appears sponsored |
| `extractionMode` | string | `listing_card` for normal cards or `static_preview` for lower-fidelity fallback rows |
| `searchUrl` | string | Search URL that produced the listing |
| `pageNumber` | number | Search result page number |
| `position` | number | Listing position on the page |
| `scrapedAt` | string | ISO timestamp of extraction |
| `source` | string | Source identifier, always `indiamart` |

### Pricing / Cost estimation

#### How much does it cost to scrape IndiaMART?

Cost depends on the number of search URLs, pagination depth, proxy settings, and how many rendered pages the Actor opens. The default run is deliberately small: one search URL, up to 20 listings, and up to 2 pages per search.

To keep costs predictable, start with the default input, inspect the output, then increase `maxItems` and `maxPagesPerSearch` gradually. For ongoing monitoring, schedule smaller recurring runs instead of one very large run when possible. Your exact cost depends on your Apify plan, proxy usage, and current platform pricing.

### Tips or Advanced options

- Use specific product terms such as material, grade, size, or machine type to reduce noisy results.
- Keep `maxConcurrency` between 1 and 3 for better reliability on rendered marketplace pages.
- Use Apify Proxy for production runs. Running without proxy can be cheaper, but it increases blocking risk.
- Keep `deduplicateResults` enabled for multi-keyword research where the same listing may appear in several searches.
- Lower `maxItems` and `maxPagesPerSearch` for quick automated checks, demos, and trial runs.
- Enable `debugMode` only when troubleshooting selectors or unexpected empty output.

### FAQ, disclaimers, and support

#### Is scraping IndiaMART allowed?

You are responsible for ensuring your use complies with IndiaMART's terms, applicable robots rules, and local laws. Use the Actor responsibly, avoid abusive request volumes, and do not use scraped data in ways that violate site policies or legal requirements.

#### Why does the Actor use Playwright?

IndiaMART search pages can render listing cards client-side. A static HTML request may return only the application shell, so this Actor uses Playwright and then optimizes browser work by blocking heavy resources and bounding pagination. If IndiaMART serves a reduced static preview page, rows are marked with `extractionMode: "static_preview"` so you can distinguish them from normal rendered listing cards.

#### What are the limitations?

The default mode focuses on search result listings, not full product-detail pages or seller profile enrichment. Some fields may be missing when IndiaMART does not display them on the result card, and selectors may need maintenance if the website changes.

#### Where can I get help?

Use the Actor's **Issues** tab for bugs, feature requests, or support. Custom extensions can add full product-page enrichment, seller profile extraction, category crawling, custom filters, or integration-specific output.

# Actor input Schema

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

One or more IndiaMART search result URLs. Keep the default steel search for a quick test run.

## `searchTerms` (type: `array`):

Optional product keywords. The Actor converts each term into an IndiaMART search URL and adds it to the crawl.

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

Maximum number of product listing records to save across all searches.

## `maxPagesPerSearch` (type: `integer`):

Maximum number of paginated result pages to visit for each search URL or search term.

## `maxConcurrency` (type: `integer`):

Maximum number of browser pages processed in parallel. Keep this modest to reduce blocking.

## `maxRunTimeSeconds` (type: `integer`):

Wall-clock safety budget in seconds. The Actor stops cleanly and keeps partial results when the limit is reached.

## `includeSponsored` (type: `boolean`):

Whether to keep cards that appear to be sponsored or advertising placements.

## `deduplicateResults` (type: `boolean`):

Remove duplicate listings using cleaned listing URLs and supplier/title fallback keys.

## `minDelayMs` (type: `integer`):

Minimum delay in milliseconds after processing each page.

## `maxDelayMs` (type: `integer`):

Maximum delay in milliseconds after processing each page.

## `requestTimeoutSecs` (type: `integer`):

Navigation and selector timeout for each IndiaMART result page.

## `proxyConfiguration` (type: `object`):

Proxy settings. Apify Proxy is enabled by default to improve reliability on IndiaMART.

## `debugMode` (type: `boolean`):

Enable detailed page-level extraction logs for troubleshooting.

## Actor input object example

```json
{
  "startUrls": [
    {
      "url": "https://dir.indiamart.com/search.mp?ss=steel"
    }
  ],
  "searchTerms": [
    "steel pipe",
    "industrial valves"
  ],
  "maxItems": 20,
  "maxPagesPerSearch": 2,
  "maxConcurrency": 2,
  "maxRunTimeSeconds": 270,
  "includeSponsored": true,
  "deduplicateResults": true,
  "minDelayMs": 250,
  "maxDelayMs": 900,
  "requestTimeoutSecs": 20,
  "proxyConfiguration": {
    "useApifyProxy": true
  },
  "debugMode": false
}
```

# Actor output Schema

## `dataset` (type: `string`):

Dataset containing product listings, suppliers, locations, prices, and cleaned IndiaMART links.

# 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://dir.indiamart.com/search.mp?ss=steel"
        }
    ],
    "searchTerms": [
        "steel pipe",
        "industrial valves"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("gtgyani206/indiamart-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://dir.indiamart.com/search.mp?ss=steel" }],
    "searchTerms": [
        "steel pipe",
        "industrial valves",
    ],
}

# Run the Actor and wait for it to finish
run = client.actor("gtgyani206/indiamart-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 '{
  "startUrls": [
    {
      "url": "https://dir.indiamart.com/search.mp?ss=steel"
    }
  ],
  "searchTerms": [
    "steel pipe",
    "industrial valves"
  ]
}' |
apify call gtgyani206/indiamart-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,gtgyani206/indiamart-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/QlxnlhgIbt3FwBAbZ/builds/VQfj64169X6SIKSfy/openapi.json
