# Expired Website checker (`agenscrape/expired-website-checker`) Actor

Integration actor that checks if websites from your data source are expired. Connect any scraper, specify the website field, and get enriched data with expiration status - perfect for domain hunters and web dev agencies finding leads.

- **URL**: https://apify.com/agenscrape/expired-website-checker.md
- **Developed by:** [Agenscrape](https://apify.com/agenscrape) (community)
- **Categories:** Integrations
- **Stats:** 6 total users, 2 monthly users, 0.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.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/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

## 🔍 Expired Website Checker

> **Powered by [WHOIS Domain Lookup](https://apify.com/agenscrape/whois-domain-lookup)** - Fast and reliable domain expiration data

***

Automatically identify businesses with expired or expiring websites. Connect this integration actor to any data source containing website URLs, and it will check each domain's expiration status using WHOIS data.

### ✨ Perfect for

- 🏷️ **Domain Hunters** - Find expired domains to purchase
- 💻 **Web Development Agencies** - Identify businesses that need new websites
- 📈 **Digital Marketing Agencies** - Find potential clients with outdated web presence
- 🎯 **Lead Generation** - Enrich your business data with website status

### 🔄 How It Works

```
Your Data Source Actor          This Integration Actor              Output
(Any scraper with websites)     (Expired Website Checker)           (Enriched Data)
        |                               |                                |
        v                               v                                v
   [Business Data]  ------>  [Extract Websites] ------>  [Expired: Yes/No]
   with websites             [WHOIS Lookup]              [Days until expiry]
                             [Check Status]              [Registrar info]
                                                         [Original data]
```

1. 🔗 **Connect** - Link any actor that outputs business data with website URLs
2. ⚙️ **Process** - Actor extracts domains and checks WHOIS expiration data
3. 📊 **Filter** - Get back enriched data with expiration status and lead quality indicators

### 🚀 Use as Integration

This actor is designed to work as an **Apify Integration**. After another actor finishes running, this actor automatically receives its dataset and processes it.

#### 📋 Setup Integration

1. Go to your source actor (e.g., any business scraper)
2. Navigate to **Integrations** tab
3. Click **Add integration** > **Run Actor**
4. Select **Expired Website Checker**
5. Configure the integration settings:
   - Set `websiteField` to match your source data (e.g., "website", "url", "Homepage")
   - Adjust `expirationThresholdDays` as needed

The payload from the triggering actor is automatically passed, so you don't need to manually set the dataset ID.

### 🛠️ Standalone Usage

You can also run this actor directly by providing a dataset ID:

```json
{
  "datasetId": "abc123...",
  "websiteField": "website",
  "expirationThresholdDays": 30,
  "includeAllResults": false,
  "preserveOriginalData": true
}
```

### ⚙️ Input Configuration

| Field | Type | Description | Default |
|-------|------|-------------|---------|
| `datasetId` | String | Source dataset ID containing business data | *(from integration)* |
| `websiteField` | String | Field name containing website URL | `website` |
| `expirationThresholdDays` | Integer | Flag domains expiring within this many days | `30` |
| `includeAllResults` | Boolean | Output all websites or only expired/expiring | `true` |
| `preserveOriginalData` | Boolean | Include original source data in output | `true` |
| `maxItems` | Integer | Limit items to process | *(all)* |

#### 🏷️ Website Field Examples

Different source actors use different field names for websites:

- `website`
- `url`
- `Homepage`
- `companyUrl`
- `domain`

Check your source data structure to find the correct field name.

### 📤 Output

Each result includes:

```json
{
  "website": "https://example.com",
  "domain": "example.com",
  "isExpired": false,
  "isExpiringSoon": true,
  "expirationDate": "2024-02-15T00:00:00Z",
  "daysUntilExpiration": 25,
  "status": ["clientTransferProhibited"],
  "registrar": "GoDaddy.com, LLC",
  "registrationDate": "2010-05-20T00:00:00Z",
  "whoisSuccess": true,
  "checkError": null,
  "isGoodLead": true,
  "originalData": {
    "businessName": "Example Corp",
    "phone": "+1-555-0123",
    "address": "123 Main St"
  }
}
```

#### 📋 Key Output Fields

| Field | Description |
|-------|-------------|
| ✅ `isExpired` | `true` if domain has expired |
| ⏰ `isExpiringSoon` | `true` if expiring within threshold days |
| 🎯 `isGoodLead` | `true` if expired OR expiring soon (easy filter) |
| 📅 `daysUntilExpiration` | Negative = expired, Positive = days remaining |
| 📦 `originalData` | All original fields from source (if enabled) |

### 📖 Example Workflows

#### 1. 🏷️ Domain Hunter Workflow

**Goal:** Find expired .com domains from business directories

```
Business Directory Scraper  --->  Expired Website Checker  --->  Filter: isExpired = true
                                  (websiteField: "url")          (Get expired domains)
```

#### 2. 💼 Web Development Lead Generation

**Goal:** Find businesses with websites expiring in 30 days

```
Any Business Scraper  --->  Expired Website Checker  --->  Filter: isExpiringSoon = true
                            (expirationThresholdDays: 30)  (Contact before expiry)
```

#### 3. 📊 Full Business Analysis

**Goal:** Check all leads and segment by website status

```
Your Data Source  --->  Expired Website Checker  --->  Export all results
                        (includeAllResults: true)       (Analyze in spreadsheet)
```

### 💻 API Usage

```javascript
import { ApifyClient } from 'apify-client';

const client = new ApifyClient({ token: 'YOUR_TOKEN' });

// Run with a specific dataset
const run = await client.actor('agenscrape/expired-website-checker').call({
    datasetId: 'YOUR_DATASET_ID',
    websiteField: 'website',
    expirationThresholdDays: 30,
    includeAllResults: false
});

// Get results
const { items } = await client.dataset(run.defaultDatasetId).listItems();

// Filter for good leads
const leads = items.filter(item => item.isGoodLead);
console.log(`Found ${leads.length} potential leads!`);
```

### 💡 Tips for Best Results

1. 🔍 **Check the website field name** - Before running, examine your source data to find the correct field name for websites

2. ⏱️ **Adjust threshold for your use case:**
   - Domain hunting: Set to `0` (only truly expired)
   - Sales outreach: Set to `60-90` (more time to contact)

3. 📉 **Use `includeAllResults: false`** to reduce output size when you only care about expired domains

4. 📎 **Combine with other data** - The `preserveOriginalData` option keeps all original business info for easy outreach

### ⚠️ Error Handling

Some domains may fail WHOIS lookup due to:

- 🌍 Unsupported TLDs (some country codes)
- ⏳ Rate limiting
- ❌ Invalid domain format

Failed lookups are included in output with `isExpired: null` and `checkError` explaining the issue.

### 🔗 Related Actors

- 🔍 [WHOIS Domain Lookup](https://apify.com/agenscrape/whois-domain-lookup) - Standalone WHOIS lookup actor (powers this integration)

### 🆘 Support

Having issues or need help?

- ✅ Check that your `websiteField` matches your source data
- ✅ Verify the source dataset ID is correct
- 📧 Contact support through Apify

# Actor input Schema

## `datasetId` (type: `string`):

Dataset ID from the source actor containing business data with website URLs. You can get this from another actor's run or use the integration payload.

## `websiteField` (type: `string`):

The field name in the source dataset that contains the website URL (e.g., 'website', 'url', 'domain', 'Homepage')

## `payload` (type: `object`):

Automatic payload from Apify integrations. Contains the triggering actor's run information including dataset ID.

## `expirationThresholdDays` (type: `integer`):

Consider domains as 'expiring soon' if they expire within this many days. Set to 0 to only flag already expired domains.

## `includeAllResults` (type: `boolean`):

If enabled, outputs all websites (expired and active). If disabled, only outputs expired or expiring soon websites.

## `preserveOriginalData` (type: `boolean`):

Include all original fields from the source dataset in the output (useful for keeping contact info, business names, etc.)

## `maxItems` (type: `integer`):

Maximum number of items to process from the source dataset. Leave empty to process all.

## Actor input object example

```json
{
  "websiteField": "website",
  "expirationThresholdDays": 30,
  "includeAllResults": true,
  "preserveOriginalData": 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 = {
    "websiteField": "website",
    "expirationThresholdDays": 30
};

// Run the Actor and wait for it to finish
const run = await client.actor("agenscrape/expired-website-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 = {
    "websiteField": "website",
    "expirationThresholdDays": 30,
}

# Run the Actor and wait for it to finish
run = client.actor("agenscrape/expired-website-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 '{
  "websiteField": "website",
  "expirationThresholdDays": 30
}' |
apify call agenscrape/expired-website-checker --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,agenscrape/expired-website-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/ZzhtWSTPISCti3RsO/builds/4QMRY2bBiQ5nvxtr5/openapi.json
