# Domain Health Checker: SPF, DKIM, DMARC, SSL & Security Headers (`cobalt_relay/domain-health-checker`) Actor

Bulk-check any list of domains for email deliverability (SPF, DKIM, DMARC, MTA-STS), SSL certificate expiry, DNSSEC and website security headers. Get a 0-100 score, an A-F grade, the mail and DNS provider, and plain-English fixes for every problem.

- **URL**: https://apify.com/cobalt_relay/domain-health-checker.md
- **Developed by:** [Cobalt Relay](https://apify.com/cobalt_relay) (community)
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.00 / 1,000 domain checks

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

### What does Domain Health Checker do?

Domain Health Checker audits any list of domains in bulk and tells you, in plain English, what's broken and how to fix it. For every domain you get:

- **Email security and deliverability**: SPF (including the 10-lookup limit), DKIM (30+ common selectors), DMARC policy, MTA-STS, TLS reporting and BIMI
- **SSL certificate**: issuer, expiry date, days left, trust errors and TLS version
- **Website security**: HTTP to HTTPS redirect, HSTS, Content-Security-Policy and other security headers
- **DNS**: DNSSEC, nameservers and DNS host
- **Who they use**: mail provider (Google Workspace, Microsoft 365, Zoho...), DNS host (Cloudflare, Route 53, GoDaddy...) and website platform (Shopify, WordPress, Wix...)
- **A 0–100 score and an A–F grade**, with every issue ranked by severity and a one-line fix

It only reads public information: DNS records, the TLS certificate, and the response headers of the home page. Page content is never downloaded and nothing is scanned or probed.

### Who uses it?

- **Cold email and lead-gen teams**: check prospect lists or your own sending domains before a campaign so emails don't land in spam.
- **IT service providers and MSPs**: find local businesses with spoofable domains or expiring certificates and offer to fix them.
- **Agencies**: run a quick health report for every client domain each month.
- **Security and IT teams**: audit all the domains your company owns, including forgotten ones.
- **Sales teams**: see which prospects use Google Workspace vs Microsoft 365, or Shopify vs WordPress.

### How much does it cost?

You pay **per domain checked**, and nothing else. Domains that don't exist, invalid input and lookups that time out are never charged. Set a spending limit on the run and the checker stops before going over it.

### How to use it

1. Paste your domains into **Domains**, one per line. Website URLs and email addresses work too; duplicates are removed automatically.
2. Leave both checks on, or turn off the website check if you only care about email.
3. Click **Start**. A few hundred domains usually finish in a couple of minutes.
4. Open the **Overview** tab for one row per domain, or **All issues with fixes** for a to-do list. Export to CSV, Excel or JSON, or pull results through the API.

### Input example

```json
{
  "domains": ["example.com", "https://www.shopify.com", "sales@acme.co.uk"],
  "checkEmail": true,
  "checkWebsite": true
}
```

### Output example

```json
{
  "domain": "example.com",
  "grade": "C",
  "score": 72,
  "criticalIssues": 1,
  "warnings": 1,
  "topIssue": "No DMARC record. Spoofed email using this domain isn't blocked and the owner gets no reports.",
  "mailProvider": "Google Workspace",
  "dnsProvider": "Cloudflare",
  "spf": "ok",
  "dmarcPolicy": "missing",
  "dkimSelectors": ["google"],
  "sslDaysLeft": 61,
  "sslIssuer": "Let's Encrypt",
  "httpsRedirect": true,
  "hsts": false,
  "webTechnologies": ["Cloudflare", "WordPress"],
  "issues": [
    {
      "severity": "critical",
      "area": "DMARC",
      "message": "No DMARC record. Spoofed email using this domain isn't blocked and the owner gets no reports.",
      "fix": "Publish '_dmarc' TXT 'v=DMARC1; p=none; rua=mailto:<you>' then tighten to quarantine/reject."
    }
  ],
  "details": { "...": "every raw record and measurement" },
  "checkedAt": "2026-10-15T14:00:00+00:00"
}
```

### How the score works

Every domain starts at 100. Each **critical** issue removes 20 points, each **warning** 8 and each **info** item 2. Grades: A is 90+, B is 80+, C is 70+, D is 60+, F is below 60.

Critical issues are things that let attackers spoof the domain or break the site: no SPF or DMARC, broken SPF, an expired or untrusted certificate.

### FAQ

**Why does it say "No DKIM key found" when I know I have DKIM?**
DKIM keys can only be looked up by their selector name. The checker tries the 30+ most common ones. If yours is custom, add it under **Extra DKIM selectors**. A missing DKIM key is only ever reported as "info" for this reason.

**Is this legal to run on domains I don't own?**
It reads the same public DNS records and certificate that every mail server and browser reads. It doesn't scan ports, test logins or crawl pages.

**Can I schedule it?**
Yes. Save your input as a task and add a schedule (for example monthly) to track certificate expiry and email setup over time. Use an Apify webhook or integration to send the results to Slack, Google Sheets or email.

**Something looks wrong.**
Open an issue on the Issues tab with the domain and what you expected. Fixes are usually shipped within a few days.

# Actor input Schema

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

Domains to check, one per line. You can paste website URLs or email addresses too; they're cleaned up to the domain automatically, and duplicates are removed.

## `domainsText` (type: `string`):

Alternative to the list above: paste domains separated by new lines or commas (handy for spreadsheets).

## `checkEmail` (type: `boolean`):

Checks whether the domain is protected against email spoofing and set up for good deliverability.

## `checkWebsite` (type: `boolean`):

Connects to the domain's website once to read its certificate and response headers. The page content is never downloaded.

## `dkimSelectors` (type: `array`):

DKIM keys can only be found by name. The 30 most common names are always tried; add any custom ones you know about (for example 'mailchimp' or 'k2').

## `maxConcurrency` (type: `integer`):

Higher is faster. Lower it if you see many lookup timeouts.

## `timeoutSecs` (type: `integer`):

How long to wait for each DNS lookup or website connection before giving up on it.

## `useSystemResolver` (type: `boolean`):

By default, lookups go to public resolvers (Cloudflare, Google, Quad9) for consistent results.

## Actor input object example

```json
{
  "domains": [
    "apify.com",
    "shopify.com",
    "github.com"
  ],
  "checkEmail": true,
  "checkWebsite": true,
  "maxConcurrency": 20,
  "timeoutSecs": 10,
  "useSystemResolver": false
}
```

# Actor output Schema

## `overview` (type: `string`):

One row per domain: grade, score, biggest problem, mail and DNS provider, SSL expiry.

## `issues` (type: `string`):

Every issue found, one row each, with severity and how to fix it.

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

Complete results including all raw DNS records, certificate and header details.

# 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",
        "shopify.com",
        "github.com"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("cobalt_relay/domain-health-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",
        "shopify.com",
        "github.com",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("cobalt_relay/domain-health-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",
    "shopify.com",
    "github.com"
  ]
}' |
apify call cobalt_relay/domain-health-checker --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,cobalt_relay/domain-health-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/WJQ4aRcod52dhRS5s/builds/t6eQK9OWvkhZDsfAn/openapi.json
