F
Official Dev Tools

Filesystem

Anthropic's official local filesystem server with read, write, and search.

Works with: Claude DesktopClaude CodeCursorWindsurfClineVS Code (Continue)Zed
Quick install
npx -y @modelcontextprotocol/server-filesystem /path/to/dir

How to install the Filesystem MCP server

Add this to your Claude Desktop MCP configuration:

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-filesystem",
        "/path/to/dir"
      ]
    }
  }
}

Add this to your Claude Code MCP configuration:

npx -y @modelcontextprotocol/server-filesystem /path/to/dir

Add this to your Cursor MCP configuration:

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-filesystem",
        "/path/to/dir"
      ]
    }
  }
}

Add this to your Windsurf MCP configuration:

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-filesystem",
        "/path/to/dir"
      ]
    }
  }
}

Add this to your Cline MCP configuration:

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-filesystem",
        "/path/to/dir"
      ]
    }
  }
}

Add this to your VS Code (Continue) MCP configuration:

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-filesystem",
        "/path/to/dir"
      ]
    }
  }
}

Add this to your Zed MCP configuration:

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-filesystem",
        "/path/to/dir"
      ]
    }
  }
}

The Filesystem MCP server is the foundational building block for any Claude workflow that involves local files. It reads, writes, lists, and searches across a configurable set of directories. Most other MCP servers assume you have this one installed alongside them.

This is also the server most beginners install first. Anthropic ships it with npx -y @modelcontextprotocol/server-filesystem /path/to/dir, scoped to whatever paths you pass in. No daemon, no background process, no API key required.

Why use it

Without filesystem access, Claude can’t read your code, your notes, your CSVs, or anything else on your machine. With it, every other workflow you build on top becomes possible.

For Claude Code, filesystem access is implicit and non-optional. For Claude Desktop, you opt in by adding the server to your config. Most users scope it to one or two project directories rather than the whole drive.

What it actually does

Five primitives: read a file, write a file, list a directory, search for filenames, search file contents. Claude composes these into bigger workflows automatically.

Practical patterns:

  • “Read every Markdown file in this directory and summarize the headings.”
  • “Find every TypeScript file that imports from ’./utils/legacy’ and refactor them.”
  • “Create a new file at ./notes/2026-05-07.md with today’s meeting agenda.”

Gotchas

Scopes are absolute paths passed at startup. You cannot dynamically add scopes mid-session. To change scopes, edit the MCP config and restart the client. This is intentional: it prevents prompt injection from expanding the file scope.

Symbolic links are followed. If a directory you scoped contains a symlink to elsewhere, the server will read through it. Audit your symlinks if you scope something like ~/projects.

Large directory trees can slow down search. The server isn’t optimized for codebases with millions of files. If you’re hitting limits, scope to a smaller subdirectory or use the Git MCP server instead, which uses git’s index for faster search.

Filesystem MCP server: FAQs

Is it safe to give Claude filesystem access?

It's as safe as the directories you scope it to. Pass the server only the paths you want exposed. Never give it your home directory root. Default to project-specific scopes and expand only when needed.

Can it delete files?

Yes, but Claude Desktop will prompt for confirmation. In Claude Code with auto-approve enabled, deletes will run without a prompt — be careful. Most users scope the server to a single project directory to limit blast radius.

How is it different from the Git MCP server?

Filesystem reads any file. Git reads the version-controlled state of a repo (commits, branches, diffs). Use both together for full coverage when working in a codebase.

Does it support writing files?

Yes. The server can create, edit, and delete files within its allowed scopes. This is what makes Claude Code's file edits work end-to-end.

Can I use multiple instances with different scopes?

Yes. Some users run two filesystem servers — one read-only against shared docs, one read-write against a specific working project — and Claude picks the right one based on context.