# Pagine Gialle Scraper - Italian Business Leads, Email & P.IVA (`neverempty/pagine-gialle-scraper`) Actor

For B2B lead lists and local sales teams: Italian businesses from Pagine Gialle by category and town, postcode or region, with email, phone in +39 format, WhatsApp, website, VAT number (P.IVA), address, coordinates and hours. Watch mode returns only new or changed businesses.

- **URL**: https://apify.com/neverempty/pagine-gialle-scraper.md
- **Developed by:** [NeverEmpty](https://apify.com/neverempty) (community)
- **Categories:** Lead generation, Automation, Developer tools
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $6.90 / 1,000 business returneds

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

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Pagine Gialle Scraper - Italian Business Leads, Email & P.IVA

Get **Italian businesses from Pagine Gialle (paginegialle.it)** as clean JSON, CSV or Excel: business name and legal name, category, full address with postcode, town, province and region, phone numbers as shown and in **+39 (E.164) format**, **WhatsApp**, **e-mail**, website and its domain, **VAT number (P.IVA)** and tax code (codice fiscale), coordinates, opening hours, rating and listing type. Search by **category or business name** (dentista, avvocato, idraulico, commercialista, ristoranti ...) in any Italian **town, 5-digit postcode or region**. Turn on **Watch mode** and scheduled runs return **only businesses that are new on the list or whose name, address, phone, website or WhatsApp changed** - so a lead list, CRM or local sales team gets the new ones without paying for the same businesses again.

- **E-mail, P.IVA and coordinates on every row where the business published them.** Each business's own page is read too, so `email`, `vatNumber`, `taxCode`, `legalName`, `latitude`/`longitude` and the full opening hours come with the row - not only what the result list shows.
- **Filter-ready flags.** `hasEmail`, `hasWhatsApp`, `hasWebsite` and `hasVatNumber` are true/false on every row, so a spreadsheet filter or a CRM import rule needs no extra work.
- **One row per business, not per listing.** Pagine Gialle often lists the same business twice (two categories, an old and a new entry). Listings with the same P.IVA, or the same name with the same phone or address, come back as one row; when a listing has no P.IVA, the same phone or e-mail also counts as the same business. The other entries are in `otherListings` and you pay once - also across the searches of one run.
- **Watch mode for new and changed businesses.** Rows are marked `first-check`, `new` or `changed` (with `changedFields`). A business is returned once per watch, even when several of your searches list it. Runs where nothing is new return one free row that says so.
- **Honest about the 200 limit.** Pagine Gialle shows at most 200 businesses for one search (8 pages of 25). When a list is bigger, a free row says how many were not returned and suggests a postcode or a smaller town. A watch never pretends to watch a list it cannot see completely.
- **Only the town you asked for.** A town search on Pagine Gialle mixes in businesses from nearby towns. By default only businesses whose address is in that town are returned, and a free row counts the others (`includeNearby` returns them too). When Pagine Gialle does not recognise a place at all it quietly shows Rome instead; this Actor returns a free `place-not-recognised` row rather than selling you Rome.
- **Free rows say why.** No results, an unknown category or place, nothing new, a page that could not be read, a business page that could not be read or the run's maximum charge reached - each comes back as a free row with a note.

Rows can contain personal data: many Italian businesses are sole traders, so a business name, e-mail or phone can identify a person. You are responsible for using the data lawfully (for example under the GDPR and Italian rules on marketing calls and e-mails).

Unofficial. Reads the public Pagine Gialle result pages and business pages, the same pages a person sees without logging in. It returns only the contact details a business published itself, does not decode protected e-mail addresses, and does not solve or bypass check pages.

### What you get

One row per business. Example (a production run on 2026-10-23, category `dentista` in `20121`):

```json
{
  "status": "ok",
  "changeType": null,
  "changedFields": null,
  "businessName": "Sdr S.r.l.",
  "legalName": null,
  "category": "Dentisti medici chirurghi ed odontoiatri",
  "services": [
    "devitalizzazione",
    "assistenza dentistica"
  ],
  "keywords": [],
  "description": "Lo Studio Dentistico Repubblica opera da oltre 40 anni presso la sede di Piazza della Repubblica a Milano e rappresen...",
  "address": "Piazza della Repubblica, 7 - 20121 Milano (MI)",
  "street": "Piazza della Repubblica, 7",
  "postalCode": "20121",
  "city": "Milano",
  "province": "MI",
  "region": "Lombardia",
  "phone": "02 6599421",
  "phoneE164": "+39026599421",
  "phones": [
    "02 6599421",
    "339 4691524"
  ],
  "fax": null,
  "whatsapp": "+393394691524",
  "email": "info@studiorepubblica.it",
  "emails": [
    "info@studiorepubblica.it"
  ],
  "website": "http://www.studiodentisticorepubblica.it",
  "websiteDomain": "studiodentisticorepubblica.it",
  "vatNumber": "14443940961",
  "taxCode": "14443940961",
  "latitude": 45.47817,
  "longitude": 9.19585,
  "openingHours": [
    "Monday 08:30-13:00, 14:00-18:30",
    "Tuesday 08:30-13:00, 14:00-18:30"
  ],
  "rating": 3.7,
  "ratingCount": 6,
  "hasEmail": true,
  "hasWhatsApp": true,
  "hasWebsite": true,
  "hasVatNumber": true,
  "listingType": "paid",
  "isSuggested": false,
  "isVerified": true,
  "distanceKm": null,
  "businessId": "5FC00CA9-46D8-F48E-E050-020A3E7436AB",
  "detailUrl": "https://www.paginegialle.it/studiodentisticorepubblicadeidottorivespaepollice",
  "logoUrl": "https://img.italiaonline.it/0WO5p000002skoNGAQ_Studio-Dentistico-Repubblica-dei-Dottori-Vespa-e-Pollice-logo.png",
  "businessType": "Dentist",
  "otherListings": [],
  "positionInSearch": 1,
  "listingsInSearch": 58,
  "listingsInSearchIsLowerBound": false,
  "directoryCategory": "Dentista",
  "directoryPlace": "20121",
  "searchWhat": "dentista",
  "searchWhere": "20121",
  "searchUrl": "https://www.paginegialle.it/ricerca/dentista/20121",
  "watchName": null,
  "checkedAt": "2026-10-23T20:05:38.406Z"
}
```

`description` and `openingHours` are shortened here. Checked on 2026-10-24: six rows of a production run (`dentista` in `Assago`) matched the live business pages on name, street, postcode, town, P.IVA, phones and e-mail.

| Column | Meaning |
|---|---|
| `status` | `ok` for a business row. Other values are free rows that say why nothing (or not everything) was returned (below) |
| `changeType`, `changedFields` | Watch mode only: `first-check` (first run of this watch), `new` (not returned before by this watch) or `changed`; `changedFields` lists what changed (`businessName`, `address`, `phones`, `website`, `whatsapp`). Null when watch mode is off |
| `businessName`, `legalName` | Name as listed; `legalName` is the legal name from the business page, only when it differs from the listed name |
| `category`, `services`, `keywords`, `description` | The directory's category, the services and keywords the business lists, and its short description |
| `address`, `street`, `postalCode`, `city`, `province`, `region` | Address as listed; `province` is the two-letter code (`MI`), `region` the region name (`Lombardia`) |
| `phone`, `phoneE164`, `phones` | First phone as shown, the same number as `+39...`, and every phone on the list and the business page, including the other listings of the same business (each number once) |
| `fax` | Fax number, when the business page shows one |
| `whatsapp` | WhatsApp number as `+39...`, when the business shows one |
| `email`, `emails` | First e-mail and all e-mails published on the business page |
| `website`, `websiteDomain` | Website link as listed, and its domain without `www.` |
| `vatNumber`, `taxCode` | P.IVA and codice fiscale when published on the business page |
| `latitude`, `longitude` | Coordinates of the business |
| `openingHours` | Opening hours as a list, for example `Monday 09:00-13:00` |
| `rating`, `ratingCount` | Average rating and number of reviews shown; null when there are none |
| `hasEmail`, `hasWhatsApp`, `hasWebsite`, `hasVatNumber` | True when the row has that detail |
| `listingType` | `paid`, `free`, `self-registered` or `other` - how the business is listed in the directory |
| `isSuggested`, `isVerified` | The directory marks the listing as suggested (sponsored), or the business as verified |
| `distanceKm` | Distance the directory shows from the searched place, when shown |
| `businessId`, `detailUrl`, `logoUrl`, `businessType` | The directory's ID for the business, its page, its logo and its type on that page |
| `otherListings` | Other directory entries of the same business (`businessId`, `address`, `phone`, `detailUrl`); empty when there is only one |
| `positionInSearch` | Position in the list of this search (1 = first) |
| `listingsInSearch`, `listingsInSearchIsLowerBound` | Number of businesses the directory reports for this search. For more than 200 it only says "più di 200": then `listingsInSearch` is null and `listingsInSearchIsLowerBound` is true |
| `directoryCategory`, `directoryPlace` | The category and place as the result page names them |
| `searchWhat`, `searchWhere`, `searchUrl` | The search this row came from |
| `note` | Free rows only: why nothing (or not everything) was returned |
| `watchName`, `checkedAt` | The watch name you gave, and the time of the check |

#### Free rows (not charged)

| `status` | When |
|---|---|
| `no-results` | The directory lists no business for this search. Pagine Gialle can read a town name as a town of the same name in another area ("Castel San Pietro" near Como); type the full official name (`Castel San Pietro Terme`) or the postcode |
| `not-found` | The directory does not know this category or business name |
| `place-not-recognised` | The directory does not recognise the place and would show another town; check the Italian spelling (`Reggio nell'Emilia`, `Firenze`) or use the postcode |
| `more-not-returned` | More businesses than the 200 the directory shows for one search, or, in watch mode, more than `maxResultsPerSearch`; says how many and what to do. Also used when the directory's list ended before the count it showed (everything listed was read) |
| `nearby-not-returned` | A town search: the list also had businesses from nearby towns, which were not returned; says how many and from which towns |
| `already-returned` | Businesses this run already returned for another search are not returned (or charged) again |
| `no-new-listings` | Watch mode: nothing new or changed since the previous check |
| `too-broad-to-watch` | Watch mode: the list goes on past the 200 the directory shows (for a town: the town's own businesses did not end within them), so it cannot be watched completely. Nothing is charged or remembered; watch a postcode or smaller town instead |
| `incomplete` | Some pages of the list could not be read; the businesses before them were returned. In watch mode nothing is judged, remembered or charged for that list, and the next run checks it again |
| `details-unreadable` | The page of some businesses could not be read, so they were not returned or charged. In watch mode they come back in the next run |
| `unreadable` | The directory could not be read, even after asking again from other IP addresses, or its pages changed shape |
| `blocked` | The directory refused the requests or showed a check page. This Actor does not solve or bypass check pages; that search gets this row and the other searches are still tried. If no search could be read, the run ends as failed |
| `budget-reached` | The run hit the maximum total charge you set. In watch mode the businesses not returned are not remembered, so the next run returns them |
| `bad-input` | The input could not be used |

### Input

| Field | Type | Default | Description |
|---|---|---|---|
| `categories` | list of strings | - | Categories or business names in Italian: `dentista`, `avvocato`, `idraulico`, `commercialista`, `ristoranti`, `parrucchiere` ... Leave Categories and Locations both empty to run the example `dentista` in `Milano` |
| `locations` | list of strings | - | Towns, 5-digit postcodes or regions: `Milano`, `Roma`, `Reggio nell'Emilia`, `20121`, `Lombardia` |
| `maxResultsPerSearch` | integer 1-200 | 50 | Most businesses returned for one search. In watch mode: most new or changed businesses per search in one run (the rest come next run) |
| `onlyNew` | boolean | false | Watch mode: return only businesses that are new or changed since they were last returned by this watch |
| `includeNearby` | boolean | false | For a town: also return the businesses from nearby towns that Pagine Gialle mixes into the list. Postcode and region searches are not filtered |
| `watchName` | string | - | Separate memories for watch mode, for example one per client |
| `resetMonitoringState` | boolean | false | Forget what this watch has seen, so the run is a first check again |

Each category is searched in each location (up to 10 searches per run).

### Examples

Dentists in two Milan postcodes, 100 each:

```json
{ "categories": ["dentista"], "locations": ["20121", "20122"], "maxResultsPerSearch": 100 }
```

New or changed lawyers and accountants in central Pescara, every morning (schedule this input). Postcodes keep each list under the 200 that Pagine Gialle shows, so the watch sees every business:

```json
{ "categories": ["avvocato", "commercialista"], "locations": ["65121", "65122"], "onlyNew": true, "watchName": "pescara-leads" }
```

Plumbers in a region:

```json
{ "categories": ["idraulico"], "locations": ["Umbria"], "maxResultsPerSearch": 200 }
```

### Pricing

Pay per event:

- **Business returned** - per business row (`status: ok`).
- **Watch check** - watch mode only: once per search, on a later run where the whole list was read and nothing was new or changed (that pays for reading the list). The first run of a watch, runs that return businesses, and lists that could not be read completely are not charged this.

Free rows are never charged. If you set a maximum total charge for a run, the run stops before it would go over it and says so; a run whose maximum has no room for one business does not request anything.

### Watch mode, step by step

1. First run: reads the whole list of each search (up to 200 businesses), returns up to `maxResultsPerSearch` as `first-check`, and remembers every business on the list as the starting point.
2. Later runs: read the whole list again and return businesses that were not returned before (`new`) and businesses already returned whose name, address, phone, website or WhatsApp changed (`changed`).
3. Businesses that could not be returned in a run (maximum charge reached, or their page could not be read) are not remembered, so the next run returns them. When a business page cannot be read, the next business on the list takes its place, so you still get up to `maxResultsPerSearch`.
4. If a page of a list cannot be read, that list is not judged at all in that run (nothing returned, remembered or charged); the next run checks it again.
5. A new listing of a business this watch already returned (same P.IVA; without a P.IVA, the same phone or e-mail) is not sold again as `new`.

Keep one schedule per watch name. Two overlapping runs of the same watch can both return the same business (the memory is a key-value store without transactions).

### Good to know

- Pagine Gialle shows at most 200 businesses for one search. Use postcodes or smaller towns for bigger lists.
- Pagine Gialle matches categories loosely: an unusual word can return businesses of a nearby category. Check `category` and `directoryCategory` on the first rows of a new search.
- The section "Abbiamo trovato altre attività simili" (similar businesses from other categories or places) below the results is not returned - only the businesses of the search itself.
- E-mail, P.IVA, codice fiscale and coordinates come from each business's own page and are returned only when the business published them there. E-mail is published mostly by businesses with a paid listing (`listingType: paid`): in our test runs almost every paid listing had one, free listings rarely did. Filter on `hasEmail` when you need it.
- Postcode and region searches stay inside that place; only town searches mix in nearby towns (see `includeNearby`). Some listings show only a region on the list ("Sede: Lombardia"); for a town search their town is taken from the business's own page, and they are returned only when it is the town you searched.
- Branches without a P.IVA that share one phone number or e-mail come back as one row (the other branches in `otherListings` when they are in the same search; in a later search of the same run or watch they are not returned again). If you need every branch town as its own row, run the towns as separate runs. Branches with their own phone and e-mail, or with different P.IVAs, are always separate rows.
- Categories are searched as you type them; the same word in different capitals is one search.
- The directory is read through Italian residential IP addresses. When it refuses requests even from fresh addresses, that search gets a `blocked` row and nothing is charged for it.

### Support

Questions, a field you need, or a search that does not work: open an issue on the Issues tab of this Actor. If a run does not do what you expected, post the run ID there.

### Thanks for using this Actor

We build these tools for people who run them every day, and we improve them from what users tell us.

- **Missing a field, or need another filter?** Tell us in the **Issues** tab. If the data is there, we add it.
- **Found a bug or a wrong value?** Post the run ID in the **Issues** tab. Wrong data is the thing we fix first.

If this Actor saved you time, a short review helps other people find it.

# Actor input Schema

## `categories` (type: `array`):

What to search for, in Italian as you would type it on paginegialle.it, for example dentista, avvocato, idraulico, commercialista, ristoranti, or a business name. Each one is searched in each location. Leave Categories and Locations both empty to run the example search dentista in Milano.

## `locations` (type: `array`):

Italian towns, 5-digit postcodes or regions, for example Milano, Roma, Reggio nell'Emilia, 20121, Lombardia. Categories times locations make the searches of a run (up to 10 per run). A place the directory does not recognise returns a free row instead of businesses from another town.

## `maxResultsPerSearch` (type: `integer`):

Most businesses returned for one search (one category in one location). Pagine Gialle shows at most 200 for one search; for bigger lists use towns or postcodes. Empty = 50. In watch mode it limits the new or changed businesses returned per search in one run; the rest come in the next run.

## `onlyNew` (type: `boolean`):

On: every run reads the whole list of each search and returns only businesses that were not returned before by this watch, plus businesses whose name, address, phone, website or WhatsApp changed since they were returned. The first run returns up to Max businesses per search and remembers the whole list as the starting point. A business is returned once per watch, even if several searches list it. A business with several listings (same name and phone, or same P.IVA) is returned once. A search whose list goes past the 200 that Pagine Gialle shows cannot be watched completely and returns a free row asking for a smaller area (for a town, only its own businesses need to fit).

## `includeNearby` (type: `boolean`):

Off: for a town, only businesses whose address is in that town are returned (Pagine Gialle also lists businesses from nearby towns there; a free row says how many were left out). On: the nearby ones are returned too. Postcode and region searches are not filtered.

## `watchName` (type: `string`):

Optional. Keeps separate memories for watch mode, for example one per client (letters, digits, dot, dash, underscore; up to 40). Runs with the same watch name share what has already been returned.

## `resetMonitoringState` (type: `boolean`):

On: forget everything this watch name has seen before running, so this run is a first check again.

## Actor input object example

```json
{
  "categories": [
    "dentista"
  ],
  "locations": [
    "Milano"
  ]
}
```

# Actor output Schema

## `results` (type: `string`):

One row per business: name, legal name, category, services, address with postcode, town, province and region, phones as shown and in +39 (E.164) format, WhatsApp, email, website and its domain, VAT number (P.IVA), tax code, coordinates, opening hours, rating, listing type, flags such as hasEmail and hasVatNumber, and its position in the search. Watch mode marks rows first-check, new or changed. A search with no businesses, nothing new, a place the directory does not recognise, a refused request or a run that hit its maximum charge comes back as a free row that says why.

# 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 = {
    "categories": [
        "dentista"
    ],
    "locations": [
        "Milano"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("neverempty/pagine-gialle-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 = {
    "categories": ["dentista"],
    "locations": ["Milano"],
}

# Run the Actor and wait for it to finish
run = client.actor("neverempty/pagine-gialle-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 '{
  "categories": [
    "dentista"
  ],
  "locations": [
    "Milano"
  ]
}' |
apify call neverempty/pagine-gialle-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,neverempty/pagine-gialle-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/KWCGf82KbxbLEX1un/builds/EHcoMY3l482y1S4Pt/openapi.json
