# Website Email Extractor (`alex_claw/website-email-extractor`) Actor

- **URL**: https://apify.com/alex_claw/website-email-extractor.md
- **Developed by:** [Alex](https://apify.com/alex_claw) (community)
- **Categories:** Automation
- **Features:** Limited permissions
- **Stats:** 42 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-usage

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

## Website Email Extractor

Extract emails, phone numbers, and social media profiles from any website. Crawls pages on the same domain with configurable depth and deduplicates all results.

### Features

- **Email extraction** -- finds emails in page text, mailto: links, and HTML attributes
- **Phone number extraction** -- international formats (+1-555-123-4567, +44 20 7946 0958, etc.)
- **Social media profiles** -- LinkedIn, Twitter/X, Facebook, Instagram, YouTube, GitHub
- **Smart crawling** -- follows same-domain links with configurable depth
- **Deduplication** -- all emails, phones, and profiles are deduplicated across pages
- **Source tracking** -- tracks which pages each email was found on
- **False-positive filtering** -- filters out image artifacts, example.com, test domains
- **Robots.txt respect** -- skips pages disallowed by robots.txt
- **Rate limiting** -- 0.5s delay between requests to avoid overloading servers

### Input

| Parameter | Type | Default | Description |
|-----------|------|---------|-------------|
| `urls` | array | *required* | Website URLs to extract contacts from (e.g., `https://example.com`) |
| `maxPagesPerSite` | integer | 10 | Max pages to crawl per domain |
| `crawlDepth` | integer | 2 | Link-following depth (1 = starting page only) |
| `extractPhones` | boolean | true | Extract phone numbers |
| `extractSocials` | boolean | true | Extract social media profile links |
| `proxyConfiguration` | object | none | Proxy settings for requests |

#### Example input

```json
{
    "urls": ["https://example.com", "https://another-site.org/about"],
    "maxPagesPerSite": 20,
    "crawlDepth": 3,
    "extractPhones": true,
    "extractSocials": true
}
```

### Output

Each domain produces one dataset item with all found contacts:

```json
{
    "domain": "example.com",
    "url": "https://example.com",
    "emails": ["contact@example.com", "info@example.com"],
    "phones": ["+1-555-123-4567"],
    "socialProfiles": {
        "linkedin": "https://linkedin.com/company/example",
        "twitter": "https://twitter.com/example",
        "facebook": null,
        "instagram": null,
        "youtube": null,
        "github": "https://github.com/example"
    },
    "pagesScraped": 5,
    "foundOnPages": {
        "contact@example.com": [
            "https://example.com/contact",
            "https://example.com/about"
        ],
        "info@example.com": [
            "https://example.com"
        ]
    }
}
```

### Use Cases

- **Lead generation** -- build prospect lists with verified contact information
- **Sales outreach** -- find decision-maker emails and LinkedIn profiles
- **Business directories** -- enrich company data with contact details
- **Competitor research** -- discover team members and organizational contacts
- **SEO & link building** -- find webmaster contact information
- **Market research** -- collect contact data from industry websites

### How It Works

1. For each input URL, the actor identifies the domain and fetches robots.txt
2. Starting from the input URL, it crawls pages using BFS (breadth-first search)
3. On each page, it extracts emails, phone numbers, and social media links
4. It follows same-domain links up to the configured crawl depth
5. Results are deduplicated and pushed as one dataset item per domain

### Pricing

Pay per result: $2.00 per 1,000 pages crawled.

### Limitations

- Only extracts from publicly accessible pages (no login-protected content)
- JavaScript-rendered content is not supported (static HTML only)
- Very large sites may hit the `maxPagesPerSite` limit before finding all contacts
- Phone number extraction may produce false positives on pages with many numbers
- Social media links must be standard profile URLs (custom share widgets may be missed)

# Actor input Schema

## `urls` (type: `array`):

List of website URLs to extract contact information from (e.g., https://example.com)

## `maxPagesPerSite` (type: `integer`):

Maximum number of pages to crawl per domain. Higher values find more contacts but take longer.

## `crawlDepth` (type: `integer`):

How deep to follow links. 1 = only the starting page, 2 = starting page + linked pages, etc.

## `extractPhones` (type: `boolean`):

Extract phone numbers in international formats from page content

## `extractSocials` (type: `boolean`):

Extract links to LinkedIn, Twitter/X, Facebook, Instagram, YouTube, and GitHub profiles

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

Proxy settings for requests. Recommended for scraping many sites to avoid IP blocks.

## Actor input object example

```json
{
  "urls": [
    "https://example.com"
  ],
  "maxPagesPerSite": 10,
  "crawlDepth": 2,
  "extractPhones": true,
  "extractSocials": 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 = {
    "urls": [
        "https://example.com"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("alex_claw/website-email-extractor").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 = { "urls": ["https://example.com"] }

# Run the Actor and wait for it to finish
run = client.actor("alex_claw/website-email-extractor").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 '{
  "urls": [
    "https://example.com"
  ]
}' |
apify call alex_claw/website-email-extractor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,alex_claw/website-email-extractor"
        }
    }
}
```

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/bGqBfKAB9iwlkrD6l/builds/ERuXX7zjOBza6Lmaa/openapi.json
