FTP MCP Server
Enables managing files across multiple FTP servers through a single MCP interface, supporting upload, listing, deletion, and public URL generation.
README
FTP MCP Server(マルチサーバー対応版)
複数のFTPサーバーに、1つのMCPサーバーからまとめてファイルをアップロード/一覧/削除するためのローカルサーバーです。
各ツール呼び出し時に server パラメータ(エイリアス)でどのサーバーを操作するか指定します。
アップロード対象はローカルの絶対パスで指定し、ファイルの中身そのものはツール呼び出しの引数に含めません
(画像などバイナリデータをLLMのコンテキストに載せずに済ませるため)。
主な用途: 生成した画像をWebサーバー上の公開フォルダにアップロードし、そのURLを
wp_upload_media_from_url(wp-mcp)に渡してWordPressのメディアライブラリに正式登録する、
という2段階のフローの前段。
1. セットアップ
cd ftp-mcp
npm install
servers.json.example を servers.json にコピーして、管理する全サーバーの情報を書きます
(このファイルには全サーバーの認証情報が入るので、絶対に公開・共有・Gitコミットしないでください。
.gitignore に含めています)。
cp servers.json.example servers.json
{
"mysite": {
"host": "ftp.example.com",
"user": "user@example.com",
"password": "xxxxxxxx",
"base_path": "/resource",
"public_base_url": "https://example.com/resource"
}
}
base_path: このサーバーのアップロード先ルートフォルダ(FTPのルートからの絶対パス)。 すべてのツールはこのbase_pathを起点にした相対パスでファイルを指定します。public_base_url:base_pathに対応する公開URLのベース。アップロード後にこれと相対パスを 結合したURLを返します。port(省略可・デフォルト21)、secure(省略可・デフォルトfalse。FTPS(暗黙的TLS)を使う場合はtrue)。
2. Claude Codeへの登録
Claude Codeを使っているプロジェクトのルートフォルダ内で .mcp.json にmcpサーバーの情報を追加します。
{
"mcpServers": {
"ftp": {
"command": "node",
"args": ["/MCPの保存パス/ftp-mcp/index.js"],
"env": {
"SERVERS_CONFIG_PATH": "/MCPの保存パス/ftp-mcp/servers.json"
}
}
}
}
3. 提供ツール
ftp_list_servers— 設定済みサーバー一覧(エイリアス・ホスト・base_path・public_base_url)を取得ftp_upload_file— ローカルファイル(絶対パス)をアップロードし、公開URLを返す。remote_pathに含まれるサブフォルダは自動作成されるftp_list_files—base_path起点の指定フォルダ内のファイル一覧を取得ftp_delete_file—base_path起点の相対パスを指定してファイルを削除 (WordPressメディアライブラリへの取り込み後、一時ファイルを掃除する用途を想定)
補足
- 依存ライブラリは
basic-ftpを使用(FTP/FTPS対応、Promiseベース)。 remote_pathに..を含むパスはエラーになります(base_path外への書き込み・削除を防ぐため)。
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.