Skip to main content
Glama
mcp-ftp-server

mcp-ftp-server

MCP FTP Server

Servidor MCP (Model Context Protocol) para operaciones FTP. Compatible con Claude Desktop y Claude CLI.

Instalación

# Clonar o copiar el proyecto
cd mcp-ftp-server

# Instalar dependencias
npm install

# Compilar
npm run build

Related MCP server: SSH Remote MCP Server

Configuración

Variables de Entorno (Recomendado)

FTP_HOST=ftp.tuservidor.com
FTP_PORT=21                    # Opcional, default: 21
FTP_USER=usuario
FTP_PASSWORD=contraseña
FTP_SECURE=false               # true para FTPS

Claude Desktop

Edita tu archivo de configuración:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "ftp": {
      "command": "node",
      "args": ["/ruta/completa/a/mcp-ftp-server/dist/index.js"],
      "env": {
        "FTP_HOST": "ftp.tuservidor.com",
        "FTP_PORT": "21",
        "FTP_USER": "tu_usuario",
        "FTP_PASSWORD": "tu_contraseña",
        "FTP_SECURE": "false"
      }
    }
  }
}

Claude CLI

Opción 1: Variables de entorno en la sesión

export FTP_HOST=ftp.tuservidor.com
export FTP_USER=usuario
export FTP_PASSWORD=contraseña
claude

Opción 2: Archivo .mcp.json en tu proyecto

{
  "mcpServers": {
    "ftp": {
      "command": "node",
      "args": ["./mcp-ftp-server/dist/index.js"],
      "env": {
        "FTP_HOST": "ftp.tuservidor.com",
        "FTP_USER": "usuario",
        "FTP_PASSWORD": "contraseña"
      }
    }
  }
}

Opción 3: Configuración global en ~/.claude/settings.json

{
  "mcpServers": {
    "ftp": {
      "command": "node",
      "args": ["/ruta/absoluta/mcp-ftp-server/dist/index.js"],
      "env": {
        "FTP_HOST": "ftp.tuservidor.com",
        "FTP_USER": "usuario",
        "FTP_PASSWORD": "contraseña"
      }
    }
  }
}

Tools Disponibles

Tool

Descripción

ftp_connect

Conectar a servidor FTP (opcional si usas env vars)

ftp_disconnect

Desconectar del servidor

ftp_status

Ver estado de la conexión

ftp_pwd

Obtener directorio actual

ftp_cd

Cambiar de directorio

ftp_list

Listar archivos y carpetas

ftp_download

Descargar archivo a local

ftp_upload

Subir archivo al servidor

ftp_read

Leer contenido de archivo remoto

ftp_write

Escribir contenido a archivo remoto

ftp_delete

Eliminar archivo

ftp_mkdir

Crear directorio

ftp_rmdir

Eliminar directorio

ftp_rename

Renombrar/mover archivo o carpeta

ftp_size

Obtener tamaño de archivo

Ejemplos de Uso

Una vez configurado, puedes pedirle a Claude:

  • "Lista los archivos en el servidor FTP"

  • "Descarga el archivo config.json del FTP a mi carpeta local"

  • "Sube el archivo backup.sql al directorio /backups en el FTP"

  • "Lee el contenido del archivo readme.txt del servidor"

  • "Crea una carpeta llamada 'proyectos' en el FTP"

  • "Muestra el estado de la conexión FTP"

Características

  • ✅ Conexión automática usando variables de entorno

  • ✅ Soporte FTPS (FTP sobre TLS)

  • ✅ Lectura/escritura de archivos en memoria

  • ✅ Creación recursiva de directorios

  • ✅ Compatible con Claude Desktop y Claude CLI

  • ✅ Manejo de errores descriptivo

Seguridad

⚠️ Importante: Las credenciales FTP se almacenan en texto plano en los archivos de configuración. Asegúrate de:

  1. No commitear archivos de configuración con credenciales a git

  2. Usar permisos restrictivos en los archivos de configuración

  3. Considerar usar FTPS (FTP_SECURE=true) para conexiones encriptadas

Desarrollo

# Modo desarrollo con recompilación automática
npm run dev

# Compilar
npm run build

# Ejecutar directamente
npm start

Licencia

MIT

Available Tools

15 tools
ftp_cdB

Change current directory on FTP server

Inputs: path (required).

ftp_connectA

Connect to an FTP server. If not called, will attempt to use FTP_HOST, FTP_USER, FTP_PASSWORD environment variables.

Inputs: host (required), user (required), password (required), port, +1 more.

ftp_deleteB

Delete a file on FTP server

Inputs: path (required).

ftp_disconnectA

Disconnect from the FTP server

Inputs: no named parameters.

ftp_downloadC

Download a file from FTP server to local filesystem

Inputs: localPath (required), remotePath (required).

ftp_listB

List files and directories in a path on FTP server

Inputs: path.

ftp_mkdirA

Create a directory on FTP server (creates parent directories if needed)

Inputs: path (required).

ftp_pwdA

Get current working directory on FTP server

Inputs: no named parameters.

ftp_readA

Read the content of a remote file (text files only)

Inputs: remotePath (required), encoding.

ftp_renameA

Rename or move a file/directory on FTP server

Inputs: newPath (required), oldPath (required).

ftp_rmdirB

Remove a directory on FTP server

Inputs: path (required), recursive.

ftp_sizeB

Get the size of a file on FTP server

Inputs: path (required).

ftp_statusA

Get current FTP connection status

Inputs: no named parameters.

ftp_uploadB

Upload a file from local filesystem to FTP server

Inputs: localPath (required), remotePath (required).

ftp_writeC

Write content to a remote file

Inputs: content (required), remotePath (required).

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.7/5.0

    Scored across 15 tools

    Disambiguation5/5

    Each tool targets a distinct FTP operation, from connection management (connect/disconnect/status) to file operations (download/upload/read/write/delete) and directory operations (cd/list/mkdir/rmdir/rename). There is clear separation between similar actions like read (viewing remote text) and download (saving to local filesystem), and between write (writing content to remote) and upload (transferring a local file). No two tools have overlapping purposes.

    Naming Consistency5/5

    All tools follow a uniform 'ftp_' prefix with a lowercase snake_case verb or command (e.g., ftp_connect, ftp_list, ftp_rename). The naming pattern is predictable and consistent, making it easy to infer functionality from the name.

    Tool Count5/5

    15 tools is well-scoped for an FTP server, covering connection management, navigation, file transfer, text editing, and directory operations. The count is within the ideal range and each tool earns its place, with no unnecessary or redundant additions.

    Completeness5/5

    The tool set provides comprehensive lifecycle coverage for FTP operations: connect/disconnect, directory management (pwd, cd, list, mkdir, rmdir), file operations (download, upload, read, write, delete, rename), and meta-operations (size, status). There are no obvious gaps for typical FTP workflows.

    Maintenance

    ActivityInactive
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      A
      maintenance
      Enables Claude to interact with FTP servers through natural language commands, allowing users to list directories, download/upload files, create directories, and delete files/directories on FTP servers.
      11
      568 npm
      37
      MIT
    • A
      license
      A
      quality
      D
      maintenance
      Enables SSH remote access to servers through Claude, allowing users to execute commands, transfer files via SFTP, and manage multiple remote connections using natural language.
      12
      9
      MIT
    • A
      license
      B
      quality
      D
      maintenance
      Enables AI agents to perform FTP/FTPS/SFTP file operations including upload, download, sync, and directory management with multi-server support.
      36
      107 npm
      8
      MIT