1. Conduid
  2. Developer Tools
  3. mark3labs/mcp-filesystem-server
MCP server · Developer Tools

mark3labs/mcp-filesystem-server

Simple Golang server for learning Model Context Protocol (MCP)

Unclaimed MIT last commit 9 months ago docs
76Good

Scored 3 hours ago · breakdown

About mark3labs/mcp-filesystem-server

mark3labs/mcp-filesystem-server is an MCP server published by mark3labs in the Developer Tools category: simple Golang server for learning Model Context Protocol (MCP). It has been installed 0 times through Conduid.

The repository has 613 stars and 102 forks, with the last commit 9 months ago. Six months or more without a commit doesn't mean the server is broken, but check the open issues (0) before depending on it in production.

Install

Install
npx mcp-filesystem-server

This server has no ConduID identity, so agent calls to it are not receipted. Pin the version you install and review the source before granting it credentials.

Ask AI

Ask AI about mark3labs/mcp-filesystem-server

Powered by Claude · Grounded in docs

I know everything about mark3labs/mcp-filesystem-server. Ask me about installation, configuration, usage, or troubleshooting.

Security checks

  • ·README presentNot checked yet.
  • ·License declaredNot checked yet.
  • ·Tests presentNot checked yet.
  • ·Dependencies pinnedNot checked yet.
  • ·No dynamic code executionNot checked yet.
  • !Scoped permissionsDoesn't declare a permission scope. Assume it can do anything its process can.

Releases

v0.11.1v0.11.1 · 22 Jun 2025Changelog 5646396f50ba144b9dd1ca9d088db0ac08cab3f8 fix: correct license copyright from Anthropic to Mark III Labs (#48) 691e319afe2cf00a2d71d05758a3e85516f6127b fix: handle file creation time retrieval correctly in getFileStats (#46)
v0.11.0v0.11.0 · 13 Jun 2025Changelog 5376de968bbc5965c0a7dafc29c19646fb131bd9 Fix test failures on macOS by resolving symlinks in allowed directories (#38) 64356dca0b16fcf450afe69ca98f8471da2670c0 Improve Docker Configuration section by adding volume mount…
v0.10.1v0.10.1 · 29 May 2025Changelog f043e09ef0e2f3e2e01ec45ce555668128c4530b chore(deps): bump docker/build-push-action from 5 to 6 (#30) 3e2e0ab85de2291fc7e9e2918e9e194d050ad816 chore(deps): bump github.com/mark3labs/mcp-go (#32)…
v0.10.0v0.10.0 · 27 May 2025What's Changed chore(deps): update mcp-go to 0.29.0 and handle the breaking changes by @jochil in https://github.com/mark3labs/mcp-filesystem-server/pull/26 Publish arm64 docker image by @aaijazi in…
v0.9.0v0.9.0 · 13 May 2025What's Changed Implement delete file by @ezynda3 in https://github.com/mark3labs/mcp-filesystem-server/pull/21 New Contributors @ezynda3 made their first contribution in https://github.com/mark3labs/mcp-filesystem-server/pull/21 Full…

README

MCP Filesystem Server

This MCP server provides secure access to the local filesystem via the Model Context Protocol (MCP).

Components

Resources

  • file://
    • Name: File System
    • Description: Access to files and directories on the local file system

Tools

File Operations

  • read_file

    • Read the complete contents of a file from the file system
    • Parameters: path (required): Path to the file to read
  • read_multiple_files

    • Read the contents of multiple files in a single operation
    • Parameters: paths (required): List of file paths to read
  • write_file

    • Create a new file or overwrite an existing file with new content
    • Parameters: path (required): Path where to write the file, content (required): Content to write to the file
  • copy_file

    • Copy files and directories
    • Parameters: source (required): Source path of the file or directory, destination (required): Destination path
  • move_file

    • Move or rename files and directories
    • Parameters: source (required): Source path of the file or directory, destination (required): Destination path
  • delete_file

    • Delete a file or directory from the file system
    • Parameters: path (required): Path to the file or directory to delete, recursive (optional): Whether to recursively delete directories (default: false)
  • modify_file

    • Update file by finding and replacing text using string matching or regex
    • Parameters: path (required): Path to the file to modify, find (required): Text to search for, replace (required): Text to replace with, all_occurrences (optional): Replace all occurrences (default: true), regex (optional): Treat find pattern as regex (default: false)

Directory Operations

  • list_directory

    • Get a detailed listing of all files and directories in a specified path
    • Parameters: path (required): Path of the directory to list
  • create_directory

    • Create a new directory or ensure a directory exists
    • Parameters: path (required): Path of the directory to create
  • tree

    • Returns a hierarchical JSON representation of a directory structure
    • Parameters: path (required): Path of the directory to traverse, depth (optional): Maximum depth to traverse (default: 3), follow_symlinks (optional): Whether to follow symbolic links (default: false)

Search and Information

  • search_files

    • Recursively search for files and directories matching a pattern
    • Parameters: path (required): Starting path for the search, pattern (required): Search pattern to match against file names
  • search_within_files

    • Search for text within file contents across directory trees
    • Parameters: path (required): Starting directory for the search, substring (required): Text to search for within file contents, depth (optional): Maximum directory depth to search, max_results (optional): Maximum number of results to return (default: 1000)
  • get_file_info

    • Retrieve detailed metadata about a file or directory
    • Parameters: path (required): Path to the file or directory
  • list_allowed_directories

    • Returns the list of directories that this server is allowed to access
    • Parameters: None

Features

  • Secure access to specified directories
  • Path validation to prevent directory traversal attacks
  • Symlink resolution with security checks
  • MIME type detection
  • Support for text, binary, and image files
  • Size limits for inline content and base64 encoding

Getting Started

Installation

Using Go Install

go install github.com/mark3labs/mcp-filesystem-server@latest

Usage

As a standalone server

Start the MCP server with allowed directories:

mcp-filesystem-server /path/to/allowed/directory [/another/allowed/directory ...]

As a library in your Go project

package main

import (
	"log"
	"os"

	"github.com/mark3labs/mcp-filesystem-server/filesystemserver"
)

func main() {
	// Create a new filesystem server with allowed directories
	allowedDirs := []string{"/path/to/allowed/directory", "/another/allowed/directory"}
	fs, err := filesystemserver.NewFilesystemServer(allowedDirs)
	if err != nil {
		log.Fatalf("Failed to create server: %v", err)
	}

	// Serve requests
	if err := fs.Serve(); err != nil {
		log.Fatalf("Server error: %v", err)
	}
}

Usage with Model Context Protocol

To integrate this server with apps that support MCP:

{
  "mcpServers": {
    "filesystem": {
      "command": "mcp-filesystem-server",
      "args": ["/path/to/allowed/directory", "/another/allowed/directory"]
    }
  }
}

Docker

Running with Docker

You can run the Filesystem MCP server using Docker:

docker run -i --rm ghcr.io/mark3labs/mcp-filesystem-server:latest /path/to/allowed/directory

Docker Configuration with MCP

To integrate the Docker image with apps that support MCP:

{
  "mcpServers": {
    "filesystem": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/mark3labs/mcp-filesystem-server:latest",
        "/path/to/allowed/directory"
      ]
    }
  }
}

If you need changes made inside the container to reflect on the host filesystem, you can mount a volume. This allows the container to access and modify files on the host system. Here's an example:

{
  "mcpServers": {
    "filesystem": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "--volume=/allowed/directory/in/host:/allowed/directory/in/container",
        "ghcr.io/mark3labs/mcp-filesystem-server:latest",
        "/allowed/directory/in/container"
      ]
    }
  }
}

License

See the LICENSE file for details.

README mirrored from the source repository 3 hours ago. The original is authoritative.

Questions

About mark3labs/mcp-filesystem-server

How do I install mark3labs/mcp-filesystem-server?

Run npx mcp-filesystem-server, then add the server to your MCP client's configuration. Conduid has recorded 0 installs, so the command is known to work with current clients.

Is mark3labs/mcp-filesystem-server safe to use with an AI agent?

Its trust score is 76 out of 100 (good). It passes 0 of 1 static security checks; the failures are listed above. It has no ConduID identity yet, so agent calls to it are not receipted.

Is mark3labs/mcp-filesystem-server still maintained?

The last commit was 9 months ago, with 0 open issues. That's long enough that you should check whether the maintainer is responding to issues before depending on it.