# Email Security Checker - SPF, DMARC, DKIM, MTA-STS (`propped_cloak/email-security-checker`) Actor

Audit email security in bulk: SPF (with the 10-lookup limit), DMARC policy, DKIM selectors, MTA-STS, TLS-RPT, BIMI and mail provider, with an A-F grade and fixes. $2 per 1,000 domains.

- **URL**: https://apify.com/propped_cloak/email-security-checker.md
- **Developed by:** [Emmanuel Vingadassalon](https://apify.com/propped_cloak) (community)
- **Categories:** Developer tools, Automation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.60 / 1,000 domain checkeds

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

## Email Security Checker - SPF, DMARC, DKIM, MTA-STS

Audit the email security of hundreds of domains in one run: **SPF (with the 10-lookup limit), DMARC policy, DKIM selectors, MTA-STS, TLS-RPT, BIMI and mail provider**. Each domain gets an **A-F grade with the exact issues to fix**.

- **Real SPF check.** Includes and redirects are followed recursively to count DNS lookups. Above 10, SPF fails with a permerror that most checkers miss (counting stops there: `spfLookups` shows 11). Multiple SPF records and `+all` are flagged.
- **DMARC that matters.** You get the policy (`none`, `quarantine`, `reject`), the subdomain policy, `pct` and whether reports are sent. Report addresses are masked (`***@domain`), so the output holds no personal data.
- **DKIM discovery.** 21 common selectors are probed (Google, Microsoft 365, Mailchimp, SendGrid, Postmark, Zoho, Proton, Fastmail...), and you can add your own.
- **Plain-language issues.** For example: "DMARC policy is p=none: spoofed e-mails are still delivered."
- **Safe by design.** Only public DNS records are read: no mailbox is contacted and no e-mail is sent. **$2 per 1,000 domains.**

### What can I use it for?

- **Deliverability audits** for your domains, or for your clients' domains if you run an agency.
- **Security due diligence:** find suppliers or acquisitions that can be spoofed (no DMARC, `p=none`, broken SPF).
- **Lead qualification for email and security services:** a domain with grade D or F needs help.
- **Monitoring:** schedule a weekly run and alert when a grade drops.

### Input

```json
{
    "domains": ["apify.com", "https://www.github.com", "contact@example.org"],
    "extraDkimSelectors": ["mycompany2024"]
}
```

E-mail addresses are accepted, but only their domain is used and returned.

### Output

One row per domain. Example from a real run:

```json
{
    "domain": "github.com",
    "mx": [{ "priority": 0, "exchange": "github-com.mail.protection.outlook.com" }],
    "mailProvider": "Microsoft 365",
    "spf": "v=spf1 ip4:192.30.252.0/22 include:spf.protection.outlook.com include:_netblocks.google.com ... ~all",
    "spfMultipleRecords": false,
    "spfAll": "~all",
    "spfLookups": 10,
    "spfErrors": [],
    "dmarc": "v=DMARC1; p=quarantine; sp=reject; pct=100; rua=mailto:***@github.com; ruf=mailto:***@github.com; fo=1",
    "dmarcPolicy": "quarantine",
    "dmarcSubdomainPolicy": "reject",
    "dmarcPct": 100,
    "dmarcReports": true,
    "dkimSelectorsFound": ["google", "selector1", "k1", "k2", "s1", "s2"],
    "mtaSts": false,
    "tlsRpt": false,
    "bimi": false,
    "score": 95,
    "grade": "A",
    "issues": [
        "No MTA-STS: TLS is not enforced for incoming mail.",
        "No TLS-RPT: no reports about TLS delivery problems."
    ],
    "error": null,
    "checkedAt": "2026-10-12T12:13:56.505Z"
}
```

**Grading:** the score starts at 100 and loses points for each problem:

| Problem | Points lost |
|---|---|
| No SPF | 25 |
| SPF with `+all` | 25 |
| SPF over 10 lookups | 15 |
| No DMARC | 30 |
| DMARC with `p=none` | 15 |
| No DKIM on common selectors | 10 |
| No MTA-STS / no TLS-RPT | 3 / 2 |

The grade is A from 90 points, B from 75, C from 60 and D from 40.

### Pricing

**$0.002 per domain checked ($2 per 1,000 domains)**, plus Apify's small run-start fee. Invalid inputs and DNS errors are free.

### Use it from AI agents (MCP)

Add `email-security-checker` to the [Apify MCP server](https://mcp.apify.com) in your MCP client (Claude, Cursor, VS Code...).

### Integrations

Apify API, schedules, webhooks, Make, Zapier, n8n. Export as JSON, CSV, Excel or HTML.

### Related tools

Same developer, same pay-per-result pricing, outputs that chain together:

- [Bulk WHOIS Lookup](https://apify.com/propped_cloak/whois-dns-domain-lookup): registrar, creation and expiry dates, DNS and mail provider of domain lists.
- [SSL Certificate Checker](https://apify.com/propped_cloak/ssl-certificate-checker): SSL certificate expiry, issuer and chain of many hosts.
- [Security Headers Checker](https://apify.com/propped_cloak/security-headers-checker): HSTS, CSP and other security headers, graded A+ to F.

### FAQ

**No DKIM found, but I'm sure the domain signs its e-mails.** DKIM keys live under a selector chosen by the sender, and selectors cannot be listed. Add yours in `extraDkimSelectors`.

**Need registrar, expiry and SSL data too?** Use [WHOIS & DNS Domain Lookup](https://apify.com/propped_cloak/whois-dns-domain-lookup).

**Something wrong or missing?** Open an issue on the Issues tab.

# Actor input Schema

## `domains` (type: `array`):

Domains, URLs or e-mail addresses, one per line. Only the domain is used and returned: no mailbox is contacted.

## `extraDkimSelectors` (type: `array`):

Optional, up to 20. DKIM selectors to try in addition to the common ones (google, selector1, selector2, k1, s1, default...).

## Actor input object example

```json
{
  "domains": [
    "apify.com",
    "github.com",
    "example.org"
  ]
}
```

# Actor output Schema

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

One row per domain: SPF with lookup count, DMARC policy, DKIM selectors, MTA-STS, TLS-RPT, BIMI, A-F grade and issues to fix.

# 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 = {
    "domains": [
        "apify.com",
        "github.com",
        "example.org"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("propped_cloak/email-security-checker").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 = { "domains": [
        "apify.com",
        "github.com",
        "example.org",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("propped_cloak/email-security-checker").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 '{
  "domains": [
    "apify.com",
    "github.com",
    "example.org"
  ]
}' |
apify call propped_cloak/email-security-checker --silent --output-dataset

```

## MCP server setup

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

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/PQo0I6r8krJf5gES9/builds/XUTfmakhN4XJKdIpE/openapi.json
