# Contact Details Scraper — Emails, Phones & Social Links (`sturdydata/contact-details-scraper`) Actor

Give it a list of websites, get back one clean contact profile per site: emails (incl. de-obfuscated), phone numbers, and social profiles (LinkedIn, X, Facebook, Instagram, YouTube, TikTok, GitHub) — each with the exact page it was found on. Precision-first: no junk emails, no false-positive phon...

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

## Pricing

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

## Contact Details Scraper — Emails, Phones & Social Links

Give it a list of websites. Get back **one clean, aggregated contact profile per website**: emails, phone numbers, and social profiles — each with the exact page it was found on, so you can verify every value.

Built for lead enrichment, CRM hygiene, outreach list building, and market research.

### Why this scraper

Most contact scrapers charge per *page* crawled and flood you with junk: image filenames that look like emails, random digit strings tagged as phones, share-button links tagged as social profiles. This actor is **precision-first**:

- **1 result = 1 website** (not 1 page). You pay for profiles, not crawl noise.
- `mailto:` and `tel:` links are trusted first; text extraction uses conservative patterns and de-obfuscation (`name [at] company [dot] com` → `name@company.com`).
- Junk filters: image/CDN filenames, placeholder domains (`example.com`, `yourdomain.com`), tracker domains never appear in output.
- Social links are canonicalized profile URLs — share/intent/login links are excluded.
- Contact-like pages (`/contact`, `/about`, `/team`, `/imprint`, `/support`, `/legal`) are crawled **first**, so a 15-page budget finds what a dumb 100-page crawl misses.
- **Robots.txt is respected.** Public pages only. No login walls, no evasion.

No browser. Pure HTTP + HTML parsing — fast and cheap to run.

### Input

| Field | Type | Default | Notes |
|---|---|---|---|
| `startUrls` | array | — | One entry per website (`https://` optional). |
| `maxPagesPerDomain` | integer | `15` | Crawl budget per site. Contact pages are prioritized. |
| `maxDepth` | integer | `2` | Link depth from the start page. |
| `proxyConfiguration` | object | Apify Proxy | Recommended: automatic. |

```json
{
    "startUrls": [{ "url": "https://apify.com" }, { "url": "acme-industrial.com" }],
    "maxPagesPerDomain": 15
}
```

### Output schema

One dataset item per website:

```json
{
    "domain": "apify.com",
    "website": "https://apify.com/",
    "emails": [
        { "email": "hello@apify.com", "foundOn": ["https://apify.com/contact"] }
    ],
    "phones": [
        { "phone": "+13024561234", "foundOn": ["https://apify.com/contact"] }
    ],
    "socialProfiles": {
        "linkedIn": ["https://www.linkedin.com/company/apifytech"],
        "twitter": ["https://twitter.com/apify"],
        "github": ["https://github.com/apify"]
    },
    "pagesScanned": 15,
    "scrapedAt": "2026-07-04T10:00:00.000Z"
}
```

| Field | Meaning |
|---|---|
| `emails[].foundOn` | Every page the address appeared on — your audit trail. |
| `phones[]` | `tel:` links, international `+`-prefixed numbers, and strict US 3-3-4 formats like `(703) 836-9300` (normalized to `+1...`). We prefer missing a number over inventing one. |
| `socialProfiles` | Canonical profile URLs per platform (LinkedIn, X/Twitter, Facebook, Instagram, YouTube, TikTok, GitHub). |
| `pagesScanned` | Actual pages fetched for this site. |
| `error` | Only present when `pagesScanned` is `0`. Tells you why: e.g. `"Disallowed by robots.txt"` or a fetch failure reason. Every website you submit gets exactly one result item — never a silent drop. |

### Pricing

**Pay per result. 1 result = 1 website profile** (regardless of how many pages were scanned for it).

| Websites | Cost at $4.00 / 1,000 |
|---|---|
| 100 | $0.40 |
| 1,000 | $4.00 |
| 10,000 | $40.00 |

Compare: per-page pricing elsewhere at ~$1/1,000 pages × 15 pages/site ≈ $15 per 1,000 sites — and you still have to aggregate the pages yourself.

### Compliance & fair use

Public web pages only. Robots.txt honored per site. Polite rate limits (1 req/s per domain). No login-walled or paywalled content. You are responsible for using extracted contact data in line with applicable law (GDPR, CAN-SPAM, etc.) in your jurisdiction.

### Using from API / MCP / AI agents

Standard Apify actor — call it via REST API, scheduler, webhooks, or the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp) so LLM agents can invoke it as a tool:

```bash
curl -X POST "https://api.apify.com/v2/acts/<ACTOR_ID>/run-sync-get-dataset-items?token=<TOKEN>" \
  -H "Content-Type: application/json" \
  -d '{ "startUrls": [{ "url": "https://apify.com" }] }'
```

### FAQ

**Why did a site return zero emails?** Some sites keep contacts behind JavaScript or forms only. We do not guess. Check `pagesScanned` and `error` — if `pagesScanned` is 0, the `error` field says exactly why (usually robots.txt disallowed crawling, and we honored it).

**Do you verify email deliverability?** No — we extract what is published, with provenance. Pipe into a verifier if you need deliverability guarantees.

### Changelog

- **0.1.1** (2026-07) — Every submitted website now always gets a result item, even when zero pages could be fetched (robots.txt block or fetch failure) — the reason is in the new `error` field. Fixed a text-extraction bug where two adjacent links with no whitespace between them (e.g. `mailto:` link followed immediately by another link) could merge into one malformed email.
- **0.1.0** (2026-07) — Initial release: aggregated per-site profiles, contact-page prioritization, de-obfuscation, junk filters, provenance (`foundOn`), robots.txt compliance.

***

Maintained by **Sturdy Data** — boring, reliable scrapers. Report issues in the Issues tab; we respond within 24 hours.

# Actor input Schema

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

One entry per website. The scraper stays on the same site, prioritizes contact/about/imprint pages, and returns ONE aggregated contact profile per site.

## `maxPagesPerDomain` (type: `integer`):

Crawl budget per website. Contact-like pages (contact, about, team, imprint, support, legal) are visited first, so a small budget usually finds everything.

## `maxDepth` (type: `integer`):

How many clicks away from the start page to follow links. 2 is enough for almost all sites.

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

Proxy to use. Apify Proxy (automatic) is recommended for reliability.

## Actor input object example

```json
{
  "startUrls": [
    {
      "url": "https://apify.com"
    }
  ],
  "maxPagesPerDomain": 15,
  "maxDepth": 2,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# 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://apify.com"
        }
    ],
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("sturdydata/contact-details-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://apify.com" }],
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("sturdydata/contact-details-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://apify.com"
    }
  ],
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call sturdydata/contact-details-scraper --silent --output-dataset

```

## MCP server setup

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

```

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/acts/MhNibudtJWzb29uuV/builds/4SUgQMAXFUfSJf5iu/openapi.json
