# Avito.ma Scraper — Morocco Classifieds, Prices & Seller Leads (`logiover/avito-ma-scraper`) Actor

Avito.ma Scraper turns Morocco's largest classifieds marketplace into structured data. Scrape any category — cars, phones, real estate, electronics, jobs — with typed prices, old-price and discount, per-ad specifications, location, and the seller's name and published phone number on most ads. A no-c

- **URL**: https://apify.com/logiover/avito-ma-scraper.md
- **Developed by:** [Logiover](https://apify.com/logiover) (community)
- **Categories:** E-commerce, Real estate, Lead generation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.50 / 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.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

## 🇲🇦 Avito.ma Scraper — Morocco Classifieds, Prices & Seller Leads

> **Export Avito.ma listings across every category — price, seller name & phone, location and specs — to JSON, CSV or Excel. Keyless.**

![data](https://img.shields.io/badge/data-JSON%C2%B7CSV%C2%B7Excel-2b8a3e?style=flat-square) ![login](https://img.shields.io/badge/login-not%20required-0b7285?style=flat-square) ![pricing](https://img.shields.io/badge/pricing-pay%20per%20result-5f3dc4?style=flat-square)

**Avito.ma Scraper** turns Morocco's largest classifieds marketplace into structured data. Scrape any category — cars, phones, real estate, electronics, jobs — with typed prices, old-price and discount, per-ad specifications, location, and the **seller's name and published phone number** on most ads. A no-code Avito.ma API alternative on Apify.

### 📋 At a glance

| | |
|---|---|
| **Source** | avito.ma (Morocco #1 marketplace) |
| **Coverage** | All Morocco, every category |
| **Volume** | Thousands per category (deep pagination) |
| **Lead field** | Seller name + phone + shop/private |
| **Prices** | MAD + old price + discount |
| **Output** | JSON, CSV, Excel |
| **Login** | Not required |

### ❓ What is Avito.ma Scraper?

Avito.ma is Morocco's leading classifieds site. This scraper reads its GraphQL data from the page, so prices are numbers, the old price is kept beside the current one, and per-ad spec chips are flattened into a readable column. The seller block — name, shop-vs-private type and a **phone number** on most ads — is what turns a listings export into a lead list for anyone selling into Morocco.

### ⭐ Why use this scraper?

- ✅ **Seller name and phone** on most ads — a ready lead list
- ✅ **Any category** — cars, real estate, phones, electronics, jobs
- ✅ **Price, old price and discount** as separate columns
- ✅ **Per-ad specs** (storage, condition, rooms…) flattened into one column
- ✅ **Deep pagination** — thousands of ads, not page one only
- ✅ **Keyless & browserless** — low cost per row

### 📦 What data can you extract?

| Field | Description |
|---|---|
| `listingId` | Ad ID |
| `title` | Title |
| `listingUrl` | Ad URL |
| `category` | Category |
| `categoryPath` | Category path |
| `adType` | Ad type (sale/rent…) |
| `priceAmount` | Price |
| `currency` | Currency |
| `oldPriceAmount` | Old price |
| `sellerName` | Seller |
| `sellerType` | Seller type |
| `sellerPhone` | Seller phone |
| `phoneVerified` | Phone verified |
| `isShop` | Is shop |
| `isNewDevelopment` | New development |
| `location` | Location |
| `specs` | Specs |
| `description` | Description |
| `imageUrl` | Image |
| `postedAt` | Posted at |
| `country` | Country |
| `source` | Source |
| `scrapedAt` | Scraped at |

### 🎯 Use cases

- Build a Moroccan seller/lead list with phone numbers by category
- Monitor used-car or phone prices and discounts across Morocco
- Track real-estate asking prices (sale & rent) on Avito
- Compare shop vs private-seller pricing
- Feed a marketplace or price-intelligence tool with a Morocco feed

### 🚀 How to use it

1. Copy a **category path** from an Avito.ma search URL (the part after `/fr/`), e.g. `maroc/téléphones-à_vendre` or `maroc/voitures`.
2. Set **Maximum results** and click **Start**.
3. Export to JSON, CSV or Excel, or pull via the Apify API.

#### Input example

```json
{
  "categoryPath": "maroc/téléphones-à_vendre",
  "maxResults": 1000
}
```

### 💳 Pricing

Runs on a **pay-per-result** model with **Apify Store volume discounts** — higher plan tiers pay less per row and you only pay for records delivered. A **free tier** is available to try it, no credit card required.

### ⚖️ Legal

This scraper collects **publicly available** listing data only; nothing behind a login. You remain responsible for how you use the exported data, including any personal data, under GDPR and local law.

### ❔ FAQ

<details>
<summary><b>Do I need an Avito account?</b></summary>

No. Listings are public — no login, no API key.

</details>

<details>
<summary><b>Can I get the seller's phone number?</b></summary>

Yes — most ads publish the seller name and phone, exported on every row where available.

</details>

<details>
<summary><b>Which categories are covered?</b></summary>

All of them — cars, real estate, phones, electronics, jobs and more; set the category path from any Avito search URL.

</details>

<details>
<summary><b>Does it paginate beyond page 1?</b></summary>

Yes — it walks pages (via the `o` parameter) until your Maximum results is met.

</details>

<details>
<summary><b>How am I charged?</b></summary>

Pay per result — you only pay for the ads delivered.

</details>

***

<sub>Keywords: avito scraper, avito.ma scraper, avito api, morocco classifieds data, scrape avito, morocco marketplace data, avito seller leads, morocco real estate data, avito cars morocco</sub>

# Actor input Schema

## `categoryPath` (type: `string`):

Path after /fr/ from an Avito.ma search URL, e.g. maroc/téléphones-à\_vendre, maroc/voitures, maroc/appartements-à\_vendre.

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

Stop after this many ads; the Actor paginates until met.

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

Residential Morocco proxy is preselected for reliable access.

## Actor input object example

```json
{
  "categoryPath": "maroc/téléphones-à_vendre",
  "maxResults": 500,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ],
    "apifyProxyCountry": "MA"
  }
}
```

# Actor output Schema

## `listingId` (type: `string`):

No description

## `title` (type: `string`):

No description

## `listingUrl` (type: `string`):

No description

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

No description

## `categoryPath` (type: `string`):

No description

## `adType` (type: `string`):

No description

## `priceAmount` (type: `string`):

No description

## `currency` (type: `string`):

No description

## `oldPriceAmount` (type: `string`):

No description

## `sellerName` (type: `string`):

No description

## `sellerType` (type: `string`):

No description

## `sellerPhone` (type: `string`):

No description

## `phoneVerified` (type: `string`):

No description

## `isShop` (type: `string`):

No description

## `isNewDevelopment` (type: `string`):

No description

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

No description

## `specs` (type: `string`):

No description

## `description` (type: `string`):

No description

## `imageUrl` (type: `string`):

No description

## `postedAt` (type: `string`):

No description

## `country` (type: `string`):

No description

## `source` (type: `string`):

No description

## `scrapedAt` (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 = {
    "categoryPath": "maroc/téléphones-à_vendre",
    "maxResults": 500,
    "proxyConfiguration": {
        "useApifyProxy": true,
        "apifyProxyGroups": [
            "RESIDENTIAL"
        ],
        "apifyProxyCountry": "MA"
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("logiover/avito-ma-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 = {
    "categoryPath": "maroc/téléphones-à_vendre",
    "maxResults": 500,
    "proxyConfiguration": {
        "useApifyProxy": True,
        "apifyProxyGroups": ["RESIDENTIAL"],
        "apifyProxyCountry": "MA",
    },
}

# Run the Actor and wait for it to finish
run = client.actor("logiover/avito-ma-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 '{
  "categoryPath": "maroc/téléphones-à_vendre",
  "maxResults": 500,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ],
    "apifyProxyCountry": "MA"
  }
}' |
apify call logiover/avito-ma-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,logiover/avito-ma-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/3H5Wd30Wv3mexeFAE/builds/nGxjrbXuJ9y01jE9J/openapi.json
