Gives AI agents and code editors file and folder backup and restore, useful before risky code changes.
Setup
Choose your client, copy the config, then fill in any required environment variables.
claude mcp add backup --env BACKUP_DIR='<BACKUP_DIR>' --env EMERGENCY_BACKUP_DIR='<EMERGENCY_BACKUP_DIR>' --env MAX_VERSIONS='<MAX_VERSIONS>' -- npx -y @smithery/cli install @hexitex/MCP-Backup-Server --client claude~/.codex/config.toml
[mcp_servers.backup]
command = "npx"
args = ["-y", "@smithery/cli", "install", "@hexitex/MCP-Backup-Server", "--client", "claude"]
env = { BACKUP_DIR = "<BACKUP_DIR>", EMERGENCY_BACKUP_DIR = "<EMERGENCY_BACKUP_DIR>", MAX_VERSIONS = "<MAX_VERSIONS>" }
# codex mcp add backup --env BACKUP_DIR='<BACKUP_DIR>' --env EMERGENCY_BACKUP_DIR='<EMERGENCY_BACKUP_DIR>' --env MAX_VERSIONS='<MAX_VERSIONS>' -- npx -y @smithery/cli install @hexitex/MCP-Backup-Server --client claude~/.cursor/mcp.json
{
"mcpServers": {
"backup": {
"command": "npx",
"args": [
"-y",
"@smithery/cli",
"install",
"@hexitex/MCP-Backup-Server",
"--client",
"claude"
],
"env": {
"BACKUP_DIR": "<BACKUP_DIR>",
"EMERGENCY_BACKUP_DIR": "<EMERGENCY_BACKUP_DIR>",
"MAX_VERSIONS": "<MAX_VERSIONS>"
}
}
}
}.vscode/mcp.json
{
"servers": {
"backup": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@smithery/cli",
"install",
"@hexitex/MCP-Backup-Server",
"--client",
"claude"
],
"env": {
"BACKUP_DIR": "<BACKUP_DIR>",
"EMERGENCY_BACKUP_DIR": "<EMERGENCY_BACKUP_DIR>",
"MAX_VERSIONS": "<MAX_VERSIONS>"
}
}
}
}~/.gemini/settings.json
{
"mcpServers": {
"backup": {
"command": "npx",
"args": [
"-y",
"@smithery/cli",
"install",
"@hexitex/MCP-Backup-Server",
"--client",
"claude"
],
"env": {
"BACKUP_DIR": "<BACKUP_DIR>",
"EMERGENCY_BACKUP_DIR": "<EMERGENCY_BACKUP_DIR>",
"MAX_VERSIONS": "<MAX_VERSIONS>"
}
}
}
}claude_desktop_config.json
{
"mcpServers": {
"backup": {
"command": "npx",
"args": [
"-y",
"@smithery/cli",
"install",
"@hexitex/MCP-Backup-Server",
"--client",
"claude"
],
"env": {
"BACKUP_DIR": "<BACKUP_DIR>",
"EMERGENCY_BACKUP_DIR": "<EMERGENCY_BACKUP_DIR>",
"MAX_VERSIONS": "<MAX_VERSIONS>"
}
}
}
}.trae/mcp.json
{
"mcpServers": {
"backup": {
"command": "npx",
"args": [
"-y",
"@smithery/cli",
"install",
"@hexitex/MCP-Backup-Server",
"--client",
"claude"
],
"env": {
"BACKUP_DIR": "<BACKUP_DIR>",
"EMERGENCY_BACKUP_DIR": "<EMERGENCY_BACKUP_DIR>",
"MAX_VERSIONS": "<MAX_VERSIONS>"
}
}
}
}Environment variables
BACKUP_DIREMERGENCY_BACKUP_DIRMAX_VERSIONS
Replace the placeholders with your own credentials and keep them out of version control.