by Mearman
Interact with the Internet Archive's Wayback Machine through an MCP server and command‑line interface, providing URL archiving, snapshot retrieval, CDX searches, screenshot management, and comparison utilities.
Mcp Wayback Machine enables programmatic access to the Wayback Machine archives. It offers an MCP‑compatible server and a CLI tool that can save URLs, fetch archived content, search historic captures, list screenshots, compare snapshots, and clear cached responses.
npx -y mcp-wayback-machine directly via an agent harness command or add the following configuration to the harness’s config file.npx mcp-wayback-machine save https://example.com or install globally with npm install -g mcp-wayback-machine and use the wayback command.# Archive a URL
wayback save https://example.com
# Retrieve the latest snapshot
wayback get https://example.com
# Retrieve a specific snapshot
wayback get https://example.com --timestamp 20231225120000
# Search CDX index
wayback search https://example.com --from 2023-01-01 --to 2023-12-31 --limit 20
# Check archival statistics
wayback status https://example.com
# List available screenshots
wayback screenshots https://example.com
# Compare oldest and newest snapshots
wayback compare https://example.com
# Clear cached API responses
wayback clear_cache
Retry-After responses.Q: Do I need an API key to use the server?
A: No. The server works anonymously, but providing WAYBACK_ACCESS_KEY and WAYBACK_SECRET_KEY increases the save rate limit.
Q: Which Node.js version is required? A: Node.js 22 or newer.
Q: How does caching work? A: Snapshot content is cached for 24 hours, CDX/search data for 1 hour, save operations for 30 minutes, and save‑status polling for 30 seconds.
Q: Can I limit the number of outlinked pages saved?
A: Yes, the captureOutlinks parameter archives up to 100 outlinks.
Q: What transport does the MCP server use? A: Standard I/O (stdio) for seamless integration with MCP clients.
An MCP (Model Context Protocol) server and CLI tool for interacting with the Internet Archive's Wayback Machine. Supports full CDX search, snapshot content retrieval, screenshot listing, snapshot comparison, and optional authentication for higher SPN2 rate limits.
Some agent harnesses provide a one-command install:
Claude Code (MCP):
claude mcp add wayback-machine -- npx -y mcp-wayback-machine
Claude Code (plugin marketplace):
/plugin marketplace add https://github.com/Mearman/mcp-wayback-machine.git
/plugin install mcp-wayback-machine@mcp-wayback-machine
OpenAI Codex:
codex mcp add wayback-machine -- npx -y mcp-wayback-machine
To include optional credentials:
claude mcp add wayback-machine --env WAYBACK_ACCESS_KEY=xxx --env WAYBACK_SECRET_KEY=xxx -- npx -y mcp-wayback-machine
codex mcp add wayback-machine --env WAYBACK_ACCESS_KEY=xxx --env WAYBACK_SECRET_KEY=xxx -- npx -y mcp-wayback-machine
For harnesses that use config files, add the following to the appropriate section:
{
"wayback-machine": {
"command": "npx",
"args": ["-y", "mcp-wayback-machine"],
"env": {
"WAYBACK_ACCESS_KEY": "your-access-key",
"WAYBACK_SECRET_KEY": "your-secret-key"
}
}
}
| Harness | Config file | Config key |
|---|---|---|
| Claude Code | .mcp.json (project) / ~/.claude.json (user) |
mcpServers |
| Codex | ~/.codex/config.toml |
[mcp_servers.wayback-machine] |
| Gemini CLI | ~/.gemini/settings.json |
mcpServers |
| Crush | .crush.json / ~/.config/crush/crush.json |
mcp |
| Cline | .cline/mcp.json |
mcpServers |
| Cursor | .cursor/mcp.json |
mcpServers |
| Zed | ~/.config/zed/settings.json |
context_servers |
| Claude Desktop | ~/Library/Application Support/Claude/claude_desktop_config.json |
mcpServers |
The env block is optional — the server works anonymously without credentials. See Credentials for details.
npx mcp-wayback-machine save https://example.com
Or install globally:
npm install -g mcp-wayback-machine
wayback save https://example.com
What to ask the agent:
Archive https://example.com to the Wayback Machine
Find all archived snapshots of https://example.com from 2023
What's the earliest archived version of https://example.com?
Compare the oldest and newest snapshots of https://example.com
Check how many times https://example.com has been archived
save_urlArchive a URL to the Wayback Machine using the SPN2 API.
| Parameter | Required | Description |
|---|---|---|
url |
Yes | The URL to archive |
captureScreenshot |
No | Capture a screenshot as a PNG image |
captureOutlinks |
No | Also archive up to 100 outlinked pages |
ifNotArchivedWithin |
No | Skip if archived within timeframe, e.g. "30d" |
jsBehaviorTimeout |
No | Run JavaScript for N seconds before capturing (max 30) |
forceGet |
No | Use simple HTTP GET instead of browser rendering |
delayWbAvailability |
No | Delay indexing ~12 hours to reduce server load |
get_archived_urlRetrieve an archived snapshot's content and metadata.
| Parameter | Required | Description |
|---|---|---|
url |
Yes | The URL to retrieve |
timestamp |
No | Specific timestamp (YYYYMMDDhhmmss) or "latest" |
modifier |
No | URL modifier: id_ (raw), im_ (screenshot), js_ (JS), cs_ (CSS) |
search_archivesSearch the CDX API for archived versions of a URL.
| Parameter | Required | Description |
|---|---|---|
url |
Yes | The URL pattern to search for |
matchType |
No | exact, prefix, host, or domain |
from |
No | Start date (YYYYMMDD or YYYY-MM-DD) |
to |
No | End date (YYYYMMDD or YYYY-MM-DD) |
limit |
No | Maximum results (default 10) |
offset |
No | Skip the first N results |
collapse |
No | Collapse duplicates, e.g. "timestamp:8" (per hour), "digest" |
filter |
No | Filter by field regex, e.g. ["statuscode:200", "!mimetype:image.*"] |
resolveRevisits |
No | Resolve warc/revisit entries to original metadata |
showDupeCount |
No | Show duplicate count per capture |
page |
No | Page number for pagination |
pageSize |
No | Results per page |
check_archive_statusCheck archival statistics for a URL — capture counts, yearly breakdowns, and first/last capture dates.
| Parameter | Required | Description |
|---|---|---|
url |
Yes | The URL to check |
list_screenshotsList available screenshots for a URL.
| Parameter | Required | Description |
|---|---|---|
url |
Yes | The URL to find screenshots for |
limit |
No | Maximum results (default 10) |
compare_snapshotsCompare two archived snapshots of a URL. Fetches the raw content of both and provides a visual diff URL.
| Parameter | Required | Description |
|---|---|---|
url |
Yes | The URL to compare snapshots for |
timestampA |
No | First timestamp. Defaults to oldest available. |
timestampB |
No | Second timestamp. Defaults to newest available. |
clear_cacheClear all cached API responses. Use when fresh data is needed or after saving a new URL.
The server works anonymously by default. Set Internet Archive S3 credentials for higher rate limits on save operations:
export WAYBACK_ACCESS_KEY="your-access-key"
export WAYBACK_SECRET_KEY="your-secret-key"
To obtain credentials, log in to archive.org and visit your S3 API keys page.
wayback save https://example.com
wayback get https://example.com
wayback get https://example.com --timestamp 20231225120000
wayback search https://example.com --from 2023-01-01 --to 2023-12-31 --limit 20
wayback status https://example.com
wayback screenshots https://example.com
wayback compare https://example.com
wayback compare https://example.com --timestamp-a 20230101000000 --timestamp-b 20240101000000
Requires pnpm and Node.js 22+.
pnpm install
pnpm validate # typecheck + lint + test + build
ia Python CLI. Complements this project (general IA operations) vs. this server (Wayback Machine MCP protocol).Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International.
Please log in to share your review and rating for this MCP.
Explore related MCPs that share similar capabilities and solve comparable challenges
by modelcontextprotocol
A Model Context Protocol server for Git repository interaction and automation.
by zed-industries
A high‑performance, multiplayer code editor designed for speed and collaboration.
by modelcontextprotocol
Model Context Protocol Servers
by modelcontextprotocol
A Model Context Protocol server that provides time and timezone conversion capabilities.
by cline
An autonomous coding assistant that can create and edit files, execute terminal commands, and interact with a browser directly from your IDE, operating step‑by‑step with explicit user permission.
by upstash
Provides up-to-date, version‑specific library documentation and code examples directly inside LLM prompts, eliminating outdated information and hallucinated APIs.
by daytonaio
Provides a secure, elastic infrastructure that creates isolated sandboxes for running AI‑generated code with sub‑90 ms startup, unlimited persistence, and OCI/Docker compatibility.
by continuedev
Enables faster shipping of code by integrating continuous AI agents across IDEs, terminals, and CI pipelines, offering chat, edit, autocomplete, and customizable agent workflows.
by github
Connects AI tools directly to GitHub, enabling natural‑language interactions for repository browsing, issue and pull‑request management, CI/CD monitoring, code‑security analysis, and team collaboration.
{
"mcpServers": {
"wayback-machine": {
"command": "npx",
"args": [
"-y",
"mcp-wayback-machine"
],
"env": {
"WAYBACK_ACCESS_KEY": "<YOUR_ACCESS_KEY>",
"WAYBACK_SECRET_KEY": "<YOUR_SECRET_KEY>"
}
}
}
}claude mcp add wayback-machine npx -y mcp-wayback-machine