# Wayback Machine Scraper: Archived Snapshots, URL History & Text (`gmyri/wayback-machine-snapshots`) Actor

List Wayback Machine (Internet Archive) snapshots for any URL or domain, get first/last capture dates and archived page text as Markdown. $0.50 per 1,000 snapshots.

- **URL**: https://apify.com/gmyri/wayback-machine-snapshots.md
- **Developed by:** [Giorgos Myrianthous](https://apify.com/gmyri) (community)
- **Categories:** SEO tools, Developer tools, AI
- **Features:** Limited permissions
- **Stats:** 1 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.50 / 1,000 snapshots

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

## Wayback Machine Scraper: Archived Snapshots, URL History & Text

A **Wayback Machine scraper** on the official Internet Archive CDX API: list **archived snapshots** of any URL, get **first and last capture dates** and history per URL, list **all archived URLs of a domain**, and fetch an **archived page as Markdown or text** for any date.

💲 **$0.50 per 1,000 snapshots or archived URLs**, $0.002 per URL history summary, $0.002 per archived page as text. URLs with no captures are free. Pay only for results. No subscription, and the Apify free plan's monthly credit covers small jobs.

**Also known as:** Wayback Machine scraper, Internet Archive API, archive.org snapshots, archived URLs of a domain, domain history, web archive, old website content, archived page text.

### Try it now (free-plan friendly)

1. Click **Start**. The prefilled input works as is. Lists the 10 latest monthly snapshots of apify.com in about 6 seconds.
2. Or paste this input into the JSON tab:

```json
{
  "urls": [
    "apify.com"
  ],
  "mode": "snapshots",
  "maxResultsPerUrl": 10
}
```

**Example output** (one dataset item, shortened):

```json
{
  "input": "apify.com",
  "type": "snapshot",
  "capturedAt": "2026-11-04T21:52:54+00:00",
  "originalUrl": "https://apify.com/",
  "statusCode": 200,
  "mimeType": "text/html",
  "archiveUrl": "https://web.archive.org/web/20261104215254/https://apify.com/"
}
```

Small runs cost cents, and you can set a **Max cost per run** so you're never charged more.

### Use with AI agents / Apify MCP

Give your agent (Claude, ChatGPT, Cursor, n8n AI Agent, LangChain, OpenAI Agents SDK) this tool through **Apify's MCP server**:

```text
https://mcp.apify.com?tools=gmyri/wayback-machine-snapshots
```

- **Example prompt:** "When was example.com first archived, and what did its homepage say in 2010?"
- **Why agents like it:** the input has one required field and documented defaults and enums. The output has stable, flat field names, errors are returned as items with an `error` field and are never charged, and each run writes a summary to the `OUTPUT` record.
- Agents that use `search-actors` find it by searching for: Wayback Machine scraper, Internet Archive API.

### API, Python, n8n, Make, Zapier

```bash
curl -X POST "https://api.apify.com/v2/acts/gmyri~wayback-machine-snapshots/run-sync-get-dataset-items?token=$APIFY_TOKEN" \
  -H 'Content-Type: application/json' \
  -d '{"urls":["example.com"],"mode":"summary"}'
```

- **Python:** `ApifyClient(token).actor("gmyri/wayback-machine-snapshots").call(run_input={...})`
- **n8n / Make / Zapier:** use the Apify "Run Actor" action with `gmyri/wayback-machine-snapshots`, then read the dataset items.

### Quick FAQ

- **Can I get every archived URL of a domain?** Yes. Use `mode: allUrls` with `matchType: domain` (includes subdomains), `host` or `prefix`.
- **Can I read what a page said years ago?** Yes. Use `mode: pageText` and set `timestamp` (e.g. 20200101). You get the main content as Markdown.
- **Is it allowed?** It uses the Internet Archive's public CDX API at about one request per second, as the Archive asks, and returns public archived web pages only.
- **What if I set a spending limit?** The Actor stops cleanly at your *Max cost per run* and you're never charged above it.

### Details

### What it does

Uses the **Internet Archive's official Wayback Machine CDX API**. No scraping of live sites, no logins.

- **Snapshots mode:** every capture of a URL (or one per hour/day/month/year, or only when the content changed), with date, status code, MIME type, content digest, size and direct Wayback links.
- **Summary mode:** one row per URL: **first capture, latest capture**, days captured per year and days since last capture. Great for domain-age checks, expired-domain research and due diligence.
- **All archived URLs of a domain:** list every URL the Wayback Machine has for a domain, host or path prefix. Use it to recover lost pages, old sitemaps, broken backlinks and redirects after a migration.
- **Page text mode:** fetch the archived page closest to a date and get its **main content as Markdown or plain text** (or raw HTML), ready for LLMs and diffing.

### Typical uses

- SEO: recover deleted content and old URLs, plan 301 redirects, check competitors' past pricing and messaging.
- Domain research: how old is a site, when was it last alive, what was on it.
- Change tracking: one snapshot per month (or per content change) for a page over years.
- AI agents: "what did this page say in 2020?"

### Input

| Field | Description |
|---|---|
| `urls` | URLs or domains. |
| `mode` | `snapshots`, `summary`, `allUrls` or `pageText`. |
| `maxResultsPerUrl` | Max rows per input (default 100). |
| `collapse` | One snapshot per hour/day/month/year or per content change. |
| `newestFirst` | Latest captures first (default on). |
| `from`, `to` | Date range (YYYY, YYYYMM, YYYYMMDD). |
| `onlyStatus200`, `mimeTypeFilter` | Filters. |
| `matchType` | `allUrls` scope: domain, host or prefix. |
| `timestamp`, `pageFormat` | `pageText`: target date and output format. |

### Pricing

Pay per event: **$0.0005 per snapshot or archived URL ($0.50 per 1,000)**, **$0.002 per URL history summary**, **$0.002 per archived page converted to text**, plus Apify's standard $0.00005 Actor start. Inputs with no captures ("not archived") are free.

### Notes

- The Actor is polite to the Internet Archive: about one request per second with automatic back-off on rate limits, so big jobs take a little longer.
- It returns archived public web pages and capture metadata only. It does not collect personal data.
- Consider [supporting the Internet Archive](https://archive.org/donate) if it's useful to you.

### Related tools

- [Broken Link Checker & SEO Audit: 404s, Redirects, Sitemap](https://apify.com/gmyri/site-health-audit)
- [PDF & Document to Markdown Parser: DOCX, PPTX, XLSX, HTML, RAG](https://apify.com/gmyri/doc-to-markdown)
- [DNS Lookup & SSL Checker: SPF, DMARC, DKIM, Domain Expiry](https://apify.com/gmyri/domain-health-check)

💡 **Need several checks per site?** [Website Audit All-in-One](https://apify.com/gmyri/website-audit) runs SEO, broken links, PageSpeed, tech stack and SSL/DNS checks in one report for $0.03 per site.

All tools by gmyri: [doc-to-markdown](https://apify.com/gmyri/doc-to-markdown), [dataset-merge-dedup](https://apify.com/gmyri/dataset-merge-dedup), [site-health-audit](https://apify.com/gmyri/site-health-audit), [website-screenshot](https://apify.com/gmyri/website-screenshot), [domain-health-check](https://apify.com/gmyri/domain-health-check), [image-pdf-ocr](https://apify.com/gmyri/image-pdf-ocr), [tech-stack-detector](https://apify.com/gmyri/tech-stack-detector), [rss-feed-reader](https://apify.com/gmyri/rss-feed-reader), [pagespeed-checker](https://apify.com/gmyri/pagespeed-checker), [website-audit](https://apify.com/gmyri/website-audit), [audio-transcriber](https://apify.com/gmyri/audio-transcriber), [image-converter](https://apify.com/gmyri/image-converter).

# Actor input Schema

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

Page URLs or domains, e.g. example.com or https://example.com/pricing.

## `mode` (type: `string`):

What to return. 'snapshots' and 'allUrls' bill per row, 'summary' per URL, 'pageText' per archived page.

## `maxResultsPerUrl` (type: `integer`):

Maximum snapshots (or archived URLs in 'allUrls' mode) per input.

## `collapse` (type: `string`):

Snapshots mode: keep at most one capture per period. 'digest' keeps only captures where the content changed.

## `newestFirst` (type: `boolean`):

Snapshots mode: return the most recent captures first (otherwise oldest first).

## `from` (type: `string`):

Only captures on/after this date: YYYY, YYYYMM, YYYYMMDD or 2024-05-01.

## `to` (type: `string`):

Only captures on/before this date.

## `onlyStatus200` (type: `boolean`):

Skip redirects and error captures.

## `mimeTypeFilter` (type: `string`):

Optional regex on MIME type, e.g. text/html or application/pdf.

## `matchType` (type: `string`):

allUrls mode: which URLs to list.

## `timestamp` (type: `string`):

pageText mode: the capture closest to this date is used (YYYYMMDD). Empty = latest capture.

## `pageFormat` (type: `string`):

pageText mode: main content as Markdown or plain text, or the raw archived HTML.

## Actor input object example

```json
{
  "urls": [
    "apify.com"
  ],
  "mode": "snapshots",
  "maxResultsPerUrl": 10,
  "collapse": "month",
  "newestFirst": true,
  "onlyStatus200": true,
  "matchType": "domain",
  "pageFormat": "markdown"
}
```

# Actor output Schema

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

Snapshots, URL summaries or archived pages.

## `summary` (type: `string`):

Counts per run.

# 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": [
        "apify.com"
    ],
    "mode": "snapshots",
    "maxResultsPerUrl": 10
};

// Run the Actor and wait for it to finish
const run = await client.actor("gmyri/wayback-machine-snapshots").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": ["apify.com"],
    "mode": "snapshots",
    "maxResultsPerUrl": 10,
}

# Run the Actor and wait for it to finish
run = client.actor("gmyri/wayback-machine-snapshots").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": [
    "apify.com"
  ],
  "mode": "snapshots",
  "maxResultsPerUrl": 10
}' |
apify call gmyri/wayback-machine-snapshots --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,gmyri/wayback-machine-snapshots"
        }
    }
}
```

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/yzUiCHG1RvMAt3mTK/builds/Bge71riOrDllvmqxm/openapi.json
