# Gelbe Seiten Scraper — German Yellow Pages (email, phone, web) (`eudatalab/gelbeseiten-scraper`) Actor

Scrape gelbeseiten.de, Germany's Yellow Pages: company name, category, full address, phone, website, e-mail, rating, opening hours and GPS for any trade and city. Fast HTTP-only, pay per result.

- **URL**: https://apify.com/eudatalab/gelbeseiten-scraper.md
- **Developed by:** [Ihor Hrypas](https://apify.com/eudatalab) (community)
- **Categories:** Lead generation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.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.

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

## Gelbe Seiten Scraper — German Yellow Pages (email, phone, web)

Get German companies from **gelbeseiten.de** (Germany's Yellow Pages) as a clean table: name, category, street, postal code, city, district, phone (as shown and in E.164), website, e-mail, rating and review count, GPS coordinates, opening hours and social links. Search any trade or company name in any city, district or postal code — or all of Germany. Pay only per company returned.

No browser: the Actor reads the same result list the site loads when you press "Mehr Anzeigen", so it is fast (25 companies with full details in about 20 seconds on the platform) and cheap on platform usage.

### Sample output

Real rows from a staged run ("Bäckerei" in Hamburg):

| name | address | district | phone | email | website | rating |
|---|---|---|---|---|---|---|
| Bio-Bäckerei Patricia Pitzschel | Lange Reihe 93, 20099 Hamburg | St. Georg | 040 22 62 33 71 | info@brotgarten-kiel.de | http://www.brotgarten-kiel.de | 5 |
| Schanzenbäckerei GmbH | Baumwall 5, 20459 Hamburg | Neustadt | 040 30 70 94 00 | info@schanzenbaeckerei.de | http://www.schanzenbaeckerei.de | 4 |
| Dat Backhus | Hopfenstr. 5, 20359 Hamburg | St. Pauli | 040 31 76 57 70 | info@datbackhus.de | https://www.datbackhus.de | 4.5 |
| Bäckerei-Konditorei Martin Hagelstein | Bismarckstr. 98, 20253 Hamburg | Hoheluft-West | 040 4 20 63 13 | info@baeckerei-hagelstein.de | http://www.baeckerei-hagelstein.de | 5 |

One full record:

```json
{
  "url": "https://www.gelbeseiten.de/gsbiz/a3e584f8-3648-4505-9bb6-44eded46c422",
  "id": "129016209656",
  "name": "LE CROBAG GmbH & Co. KG",
  "category": "Bäckereien",
  "street": "Glockengießerwall",
  "postalCode": "20095",
  "city": "Hamburg",
  "district": "Altstadt",
  "address": "Glockengießerwall, 20095 Hamburg",
  "phone": "040 32 37 48",
  "phoneE164": "+4940323748",
  "website": "https://www.lecrobag.de/shops-de/standorte.html",
  "email": "mail@lecrobag.de",
  "rating": 4.2,
  "reviewCount": 6,
  "latitude": 53.554394,
  "longitude": 10.002787,
  "keywords": [],
  "openingHours": {
    "Montag": "04:30 – 23:30",
    "Dienstag": "04:30 – 23:30",
    "Mittwoch": "04:30 – 23:30",
    "Donnerstag": "04:30 – 23:30",
    "Freitag": "04:30 – 23:30",
    "Samstag": "04:30 – 23:30",
    "Sonntag": "04:30 – 23:30"
  },
  "socialLinks": [
    "https://www.instagram.com/lecrobag/",
    "https://www.facebook.com/lecrobag"
  ],
  "lastUpdated": "2024-11-21"
}
```

### Use cases

- **B2B lead generation**: every electrician, dentist, tax advisor or bakery in a city or postal code with phone, e-mail and website — ready for your CRM or outreach tool.
- **Local market research**: count competitors per district, compare ratings, map them with the GPS coordinates.
- **Data enrichment**: fill in missing phone numbers, websites and opening hours for a list of German businesses.
- Give an AI agent a live German business directory via the Apify MCP server (e.g. "find 20 plumbers in Köln with an e-mail address").

### Pricing

Pay per event: **$0.0015 per company**. No company, no charge. Set **Max companies** to cap the cost of a run. One company appears once per run even when the directory lists it several times (extra phone numbers, name variants).

### Input

| Field | Meaning | Default |
|---|---|---|
| What | trade, service or company name: `Zahnarzt`, `Elektriker`, `Rechtsanwalt Arbeitsrecht` | Bäckerei (form prefill) |
| Where | city, district or 5-digit postal code: `München`, `Berlin-Mitte`, `10115`; empty = all of Germany | Hamburg (form prefill) |
| Max companies | stop after N companies (= cost cap) | 100 (form: 25) |
| Open company pages | add e-mail, GPS, keywords, opening hours and social links from each company page | on |
| Proxy | Apify datacenter proxy | on |

### Output fields

`name`, `category`, `street`, `postalCode`, `city`, `district`, `address`, `phone`, `phoneE164`, `website`, `email`, `rating`, `reviewCount`, `latitude`, `longitude`, `keywords`, `openingHours` (weekday → hours), `socialLinks`, `lastUpdated` (when the entry was last edited on Gelbe Seiten), `id` (directory entry id), `url` (company page), `scrapedAt`

With *Open company pages* off you get everything except `email`, `latitude`, `longitude`, `keywords`, `openingHours`, `socialLinks` and `lastUpdated` (and `website` only when it is shown in the list).

### Limits and fair use

Only public business listings are read, the way the site's own "Mehr Anzeigen" button loads them; pages that robots.txt excludes are never requested. Reviews are not exported (they carry reviewers' names) — only the average rating and count. Respect the UWG and GDPR when you contact businesses: unsolicited advertising e-mail to companies in Germany needs at least presumed consent (§ 7 UWG).

### Problems?

Open an issue on the **Issues** tab — median response time is under 6 hours. Include the run ID.

# Actor input Schema

## `query` (type: `string`):

Search term as on gelbeseiten.de, e.g. `Zahnarzt`, `Elektriker`, `Rechtsanwalt Arbeitsrecht`, `Steuerberater` or a company name.

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

City, district or 5-digit postal code, e.g. `München`, `Berlin-Mitte`, `10115`. Leave empty for all of Germany.

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

Stop after this many companies. One company = one charged event, so this is your cost cap. The form prefills 25 for a quick first run.

## `followDetails` (type: `boolean`):

Visit each company's page to add e-mail, GPS coordinates, keywords, opening hours and social links. Slower, same price per company.

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

Apify datacenter proxies are sufficient.

## Actor input object example

```json
{
  "query": "Bäckerei",
  "location": "Hamburg",
  "maxItems": 25,
  "followDetails": true,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

## `results` (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 = {
    "query": "Bäckerei",
    "location": "Hamburg",
    "maxItems": 25,
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("eudatalab/gelbeseiten-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 = {
    "query": "Bäckerei",
    "location": "Hamburg",
    "maxItems": 25,
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("eudatalab/gelbeseiten-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 '{
  "query": "Bäckerei",
  "location": "Hamburg",
  "maxItems": 25,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call eudatalab/gelbeseiten-scraper --silent --output-dataset

```

## MCP server setup

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