Sign In

@nl4ever/sshmcp

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@nl4ever/sshmcp

SSH MCP Server — Let AI manage remote servers via SSH with zero-token SFTP file transfer, proxy support, and multi-server management using Model Context Protocol

Source
npmnpm
Version
1.2.0
Version published
Weekly downloads
153
155%
Maintainers
1
Weekly downloads
 
Created
Source

SSH MCP Server

Let AI manage your servers — with zero-token file transfers.

npm version npm downloads license MCP compatible

A Model Context Protocol (MCP) server that gives AI the power to manage remote servers via SSH — execute commands, transfer files, and manage multi-server environments with per-connection proxy support.

Features

  • 🚀 Remote Command Execution — Run any shell command on your servers
  • 📦 SFTP File Transfer — Upload / download files and directories with zero token cost
  • 🌐 Per-Connection SOCKS Proxy — Route each server through its own SOCKS4/5 proxy
  • 🖥️ Multi-Server Management — Save and switch between unlimited server configs
  • 🔗 Jump Host / Bastion Support — Reach servers behind firewalls
  • 🔑 Flexible Auth — Password, private key, SSH agent, keyboard-interactive
  • 💾 Persistent Configuration — Configure once, use across all sessions

Zero-Token File Transfer

File transfers go directly through SFTP between your machine and the server. The AI only sends a file path — it never sees or processes the file content. Transfer a 10GB database dump at the same token cost as a 1KB config file: near zero.

You: "Deploy the build to production"

AI:  upload_directory("./dist", "/var/www/app")  ← just the path
                     |
     MCP Server: local disk --SFTP--> remote server  ← direct transfer
                     |
AI:  "Deployed successfully (142 files, 38MB)"  ← only the result

Quick Start

One command. No config files to edit.

# Claude Code
claude mcp add sshmcp npx -- -y @nl4ever/sshmcp

# Or install globally first
npm install -g @nl4ever/sshmcp
claude mcp add sshmcp sshmcp

Then just tell Claude:

"Connect to my server 192.168.1.100 as root and check disk usage"

Claude will call add_server + connect + execute("df -h") automatically.

Installation

npx (No Install)

npx @nl4ever/sshmcp
npm install -g @nl4ever/sshmcp

From Source

git clone https://github.com/NikolaNddTesla/ssh-mcp-server.git
cd ssh-mcp-server
npm install && npm run build
node dist/index.js

Integration

Claude Code
claude mcp add sshmcp sshmcp
Claude Desktop

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "sshmcp": {
      "command": "npx",
      "args": ["-y", "@nl4ever/sshmcp"]
    }
  }
}
Cursor

Go to Settings > MCP and add:

{
  "mcpServers": {
    "sshmcp": {
      "command": "npx",
      "args": ["-y", "@nl4ever/sshmcp"]
    }
  }
}
Windsurf / Cline / Other MCP Clients

Any MCP-compatible client can use this server via stdio transport:

{
  "mcpServers": {
    "sshmcp": {
      "command": "npx",
      "args": ["-y", "@nl4ever/sshmcp"]
    }
  }
}

Or if installed globally:

{
  "mcpServers": {
    "sshmcp": {
      "command": "sshmcp"
    }
  }
}

What Can It Do?

15 Tools at AI's Fingertips

Connection & Servers

ToolWhat it does
connectConnect to a server
disconnectEnd current session
test_connectionTest connectivity without switching active connection
list_serversShow all configured servers
get_serverView server details (passwords auto-masked)
add_serverAdd or update a server
delete_serverRemove a server

Remote Execution

ToolWhat it does
executeRun any shell command (with configurable timeout)
write_fileWrite text content to a remote file

File Transfer (Zero Token Cost)

ToolWhat it does
upload_fileUpload a local file to the server
upload_directoryRecursively upload an entire directory
download_fileDownload a file from the server

Proxy Management

ToolWhat it does
list_proxiesShow all configured SOCKS proxies
add_proxyAdd a SOCKS4/5 proxy
delete_proxyRemove a proxy

Configuration

All settings persist in ~/.ssh-mcp/config.json. Configure once, use across all sessions.

Server with Password

add_server({
  server_id: "prod",
  name: "Production",
  host: "192.168.1.100",
  port: 22,
  username: "root",
  password: "your-password"
})

Server with Proxy (for restricted networks)

add_proxy({ proxy_id: "us", name: "US Proxy", host: "proxy.example.com", port: 1080 })

add_server({
  server_id: "overseas",
  name: "Overseas Server",
  host: "1.2.3.4",
  port: 22,
  username: "root",
  password: "your-password",
  proxy: "us"
})

All Authentication Methods

MethodParameterUse Case
PasswordpasswordMost common
Private Key Fileprivate_key.pem / id_rsa on your machine
Private Key Inlineprivate_key_contentPaste key directly (CI/CD friendly)
SSH Agentuse_agent: trueUse system ssh-agent, no password needed
Keyboard Interactivekeyboard_interactive: trueOTP / 2FA
Jump Hostjump_hostConnect through a bastion server

Requirements

  • Node.js >= 18.0.0
  • SSH access to target servers

Contributing

Issues and PRs are welcome! If you find a bug or have a feature request, please open an issue.

License

MIT

Keywords

mcp

FAQs

Package last updated on 26 Mar 2026

Related posts