# Email Validator – Syntax, MX, Disposable & Role Check (`datarelay/email-validator`) Actor

Clean e-mail lists fast and cheap: syntax, domain and MX records over DNS, disposable domains, role mailboxes, free providers and typo fixes (gnail.com → gmail.com), with a verdict per address. Optional SPF/DMARC. No SMTP probing. Pay per email.

- **URL**: https://apify.com/datarelay/email-validator.md
- **Developed by:** [DataRelay](https://apify.com/datarelay) (community)
- **Categories:** Lead generation, Marketing, Automation
- **Features:** Limited permissions, Single-tenant, Server interface
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.37 / 1,000 emails

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.
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

## Email Validator – Syntax, MX, Disposable & Role Check

Clean an e-mail list **fast and cheap** before you send: every address gets a **verdict** – `valid`, `risky`,
`disposable` or `invalid` – with the reason, from checks that never touch the recipient's mailbox:

- **Syntax** (RFC 5321 / 5322 limits, `mailto:` links, international domains).
- **Domain and mail servers** over DNS: the domain exists, has MX records (or A / AAAA implicit MX), and does not publish a "null MX".
- **Disposable domains** (10,000+ temporary mail services, updated list).
- **Role mailboxes** (`info@`, `sales@`, `support@`…) and **free providers** (Gmail, Outlook, Yahoo, Ymail, Email.com, Proton, GMX, WP…).
- **Typo fixes**: `jan@gnail.com` → suggestion `jan@gmail.com` (`risky`).
- Optional **SPF and DMARC** of each domain.

Up to 100,000 addresses per run; addresses are grouped by domain, so each domain is looked up once. Schedule it with a
**sync key** to check only new addresses of a growing list.

### Input

```json
{
    "emails": ["info@apify.com", "someone@gnail.com", "test@mailinator.com", "not-an-email"],
    "checkDomainSecurity": false
}
```

| Field                 | Default  | Meaning                                                                                                      |
| --------------------- | -------- | ------------------------------------------------------------------------------------------------------------ |
| `emails`              | `[]`     | E-mail addresses to check, up to 100,000 per run.                                                            |
| `emailsText`          | `""`     | Addresses pasted as text, separated by new lines, commas, semicolons or spaces.                              |
| `checkMailServers`    | `true`   | Look up each domain's MX (and A / AAAA implicit MX) records over DNS-over-HTTPS. Off: syntax and lists only. |
| `checkDomainSecurity` | `false`  | Also check whether each domain publishes SPF and its DMARC policy (`spf`, `dmarcPolicy`).                    |
| `maxResults`          | `100000` | Stop after this many addresses (0 = no limit). Your spending limit is respected too.                         |
| `onlyNew`             | `false`  | Check (and charge) only addresses not checked under the sync key before.                                     |
| `syncKey`             | –        | Memory key (`email-sync-<key>`, max 40 chars); setting it turns on `onlyNew`.                                |
| `syncReset`           | `false`  | Forget addresses delivered under the sync key before this run.                                               |
| `maxRunSecs`          | `0`      | Soft time budget in seconds (0 = until the platform timeout).                                                |
| `proxyConfiguration`  | No proxy | DNS-over-HTTPS needs no proxy by default.                                                                    |

### Output

```json
{
    "schemaVersion": 1,
    "status": "ok",
    "error": null,
    "scrapedAt": "2026-11-18T09:00:00.000Z",
    "searchInput": "gnail.com",
    "key": "someone@gnail.com",
    "change": null,
    "email": "someone@gnail.com",
    "verdict": "risky",
    "reason": "Likely a typo of gmail.com",
    "normalized": "someone@gnail.com",
    "localPart": "someone",
    "domain": "gnail.com",
    "syntaxValid": true,
    "domainExists": true,
    "acceptsMail": true,
    "mxHosts": ["…"],
    "role": false,
    "free": false,
    "disposable": false,
    "suggestion": "someone@gmail.com",
    "spf": null,
    "dmarcPolicy": null
}
```

- **Monitoring:** when `syncKey` or `onlyNew` is enabled, `change` is `"new"` on delivered addresses; previously checked addresses are skipped for free.
- **Free error rows:** when DNS resolution fails for a domain (`SERVFAIL`, `REFUSED`, timeout, or rate limit), the Actor emits one free row (`status: "error"` or `"blocked"`, `domain`, `emails`, `error`) and does not charge those addresses.
- **Run summary:** the `OUTPUT` key-value store record summarizes `jobs`, `results`, `duplicatesSync`, `statuses`, `stopReason`, `sync` and `chargedEvents`.

### What it does not do

The Actor **does not connect to mail servers (no SMTP probing)**: it cannot tell whether a single mailbox exists or a
domain accepts any address (catch-all). That keeps it fast, cheap and invisible to recipients' servers – use it to drop
the addresses that can never work, and fix typos, before a send.

### Pricing (pay per event)

| Event       | FREE     | BRONZE    | SILVER    | GOLD      |
| ----------- | -------- | --------- | --------- | --------- |
| `run-start` | $0.002   | $0.002    | $0.0015   | $0.001    |
| `email`     | $0.00068 | $0.000578 | $0.000476 | $0.000374 |

- `run-start` (**$0.002** on FREE) is charged once per run, only when the run delivers its first paid address.
- 1,000 addresses: **$0.682** on FREE – **$0.68 per 1,000 addresses**, $0.374 on GOLD.
- Free: addresses checked before under your `syncKey`, duplicates within a run, and domains whose DNS lookup failed. Apify's standard `apify-actor-start` event ($0.00005) applies to every run. No hidden "free plan" multiplier.

### HTTP and MCP access

This Actor also declares a single-tenant server interface (`.actor/server.json`, `.actor/openapi.json`), using the same input, source engine and result prices as batch runs. For large jobs, use batch.

- **Apify MCP:** configure `https://mcp.apify.com/?tools=datarelay/email-validator` with your Apify bearer token. This starts ordinary Actor runs.
- **DataRelay MCP:** copy this Actor's server URL from Apify Console and append `/mcp`; authenticate with the same bearer token.
- **HTTP:** POST JSON input to `<SERVER_URL>/v1/run`. `<SERVER_URL>/openapi.json` describes the request and response schemas.

Each server run belongs to your account. Default idle timeout: 60 seconds. You pay platform usage, including startup/idle time, plus existing event fees. Discovery and health checks produce no data events, but can start a billed run. A warm run charges its start event at most once on its first paid result.

Responses include a preview (first 100 rows / 1 MB), `resultCount`, `previewLimited`, `interrupted`, and links to this request's complete Dataset slice and summary. Use batch for work exceeding the 120-second soft deadline. Check `outcome`, summaries and result statuses; source limitations remain unchanged. Use the stable Actor-level server URL for clients. The server becomes available when this build is deployed and its server settings are enabled.

### Privacy

Addresses are personal data: they are processed only to check them, never stored outside your run's dataset and never
sent to telemetry. Process lists under GDPR / your consent basis.

# Actor input Schema

## `emails` (type: `array`):

Addresses to check, one per line (up to 100,000 per run).

## `emailsText` (type: `string`):

Addresses separated by new lines, commas, semicolons or spaces (e.g. a column copied from a spreadsheet).

## `checkMailServers` (type: `boolean`):

Look up each domain's MX records over DNS: domains that do not exist or accept no mail are invalid. Off: syntax and lists only.

## `checkDomainSecurity` (type: `boolean`):

Also report whether each domain publishes SPF and its DMARC policy (two more DNS lookups per domain).

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

Stop the run after this many addresses (0 = no limit). Your spending limit is respected too.

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

Check (and charge) only addresses not checked under the sync key before – for lists that grow.

## `syncKey` (type: `string`):

Name of the memory of delivered addresses (letters, digits, dashes; at most 40). Setting it turns on monitoring.

## `syncReset` (type: `boolean`):

Forget the addresses delivered under the sync key before this run.

## `maxRunSecs` (type: `integer`):

Stop starting new requests after this many seconds (0 = until the platform timeout).

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

No proxy by default: DNS over HTTPS needs no proxy.

## Actor input object example

```json
{
  "emails": [
    "info@apify.com",
    "someone@gmial.com",
    "test@mailinator.com"
  ],
  "checkMailServers": true,
  "checkDomainSecurity": false,
  "maxResults": 100000,
  "onlyNew": false,
  "syncReset": false,
  "maxRunSecs": 0,
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

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

No description

## `summary` (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 = {
    "emails": [
        "info@apify.com",
        "someone@gmial.com",
        "test@mailinator.com"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("datarelay/email-validator").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 = { "emails": [
        "info@apify.com",
        "someone@gmial.com",
        "test@mailinator.com",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("datarelay/email-validator").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 '{
  "emails": [
    "info@apify.com",
    "someone@gmial.com",
    "test@mailinator.com"
  ]
}' |
apify call datarelay/email-validator --silent --output-dataset

```

## MCP server setup

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

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/nhqljDzcSroJT6jp7/builds/FtC3Cwzd3Zbncapu4/openapi.json
