# Filesystem MCP server

Agent View of the PolicyLayer registry record for Filesystem: identity, probed posture, risk grade, and all 14 tools classified. HTML page: https://policylayer.com/tools/filesystem

## Facts

- Server id: `@modelcontextprotocol/server-filesystem`
- Ref (repo): `modelcontextprotocol/server-filesystem`
- Install: `npx -y @modelcontextprotocol/server-filesystem`
- Homepage: https://github.com/modelcontextprotocol/server-filesystem
- Registry record: grade D, identity verified
- Lifecycle: active
- Rate-limited: no
- Tools: 14 (13 with introspected schema)
- Tool categories present: Read, Write
- Context-window cost: 1666 tokens per request — https://policylayer.com/token-cost/filesystem
- Tags: filesystem
- Record last modified: 2026-07-10T04:46:32.698Z

## Tools (14)

| Tool | Category | Risk | Record |
| --- | --- | --- | --- |
| `directory_tree` | Read | Low | https://policylayer.com/tools/filesystem/directory-tree.md |
| `get_file_info` | Read | Low | https://policylayer.com/tools/filesystem/get-file-info.md |
| `list_allowed_directories` | Read | Low | https://policylayer.com/tools/filesystem/list-allowed-directories.md |
| `list_directory` | Read | Low | https://policylayer.com/tools/filesystem/list-directory.md |
| `list_directory_with_sizes` | Read | Low | https://policylayer.com/tools/filesystem/list-directory-with-sizes.md |
| `read_file` | Read | Low | https://policylayer.com/tools/filesystem/read-file.md |
| `read_media_file` | Read | Low | https://policylayer.com/tools/filesystem/read-media-file.md |
| `read_multiple_files` | Read | Low | https://policylayer.com/tools/filesystem/read-multiple-files.md |
| `read_text_file` | Read | Low | https://policylayer.com/tools/filesystem/read-text-file.md |
| `search_files` | Read | Low | https://policylayer.com/tools/filesystem/search-files.md |
| `create_directory` | Write | Medium | https://policylayer.com/tools/filesystem/create-directory.md |
| `edit_file` | Write | Medium | https://policylayer.com/tools/filesystem/edit-file.md |
| `move_file` | Write | Medium | https://policylayer.com/tools/filesystem/move-file.md |
| `write_file` | Write | Medium | https://policylayer.com/tools/filesystem/write-file.md |

## Tool descriptions

- `directory_tree` — Get a recursive tree view of files and directories as a JSON structure. Each entry includes 'name', 'type' (file/directory), and 'children' for directories. Files have no children array, while directories always have a children array (wh…
- `get_file_info` — Retrieve detailed metadata about a file or directory. Returns comprehensive information including size, creation time, last modified time, permissions, and type. This tool is perfect for understanding file characteristics without reading…
- `list_allowed_directories` — Returns the list of directories that this server is allowed to access. Subdirectories within these allowed directories are also accessible. Use this to understand which directories and their nested paths are available before trying to ac…
- `list_directory` — Get a detailed listing of all files and directories in a specified path. Results clearly distinguish between files and directories with [FILE] and [DIR] prefixes. This tool is essential for understanding directory structure and finding s…
- `list_directory_with_sizes` — Get a detailed listing of all files and directories in a specified path, including sizes. Results clearly distinguish between files and directories with [FILE] and [DIR] prefixes. This tool is useful for understanding directory structure…
- `read_file` — Read the complete contents of a file as text. DEPRECATED: Use read_text_file instead.
- `read_media_file` — Read a file and return it as a base64-encoded content block with its MIME type. Image and audio files are returned as image/audio content; any other file type is returned as an embedded resource. Only works within allowed directories.
- `read_multiple_files` — Read the contents of multiple files simultaneously. This is more efficient than reading files one by one when you need to analyze or compare multiple files. Each file's content is returned with its path as a reference. Failed reads for i…
- `read_text_file` — Read the complete contents of a file from the file system as text. Handles various text encodings and provides detailed error messages if the file cannot be read. Use this tool when you need to examine the contents of a single file. Use …
- `search_files` — Recursively search for files and directories matching a pattern. The patterns should be glob-style patterns that match paths relative to the working directory. Use pattern like '*.ext' to match files in current directory, and '/*.ext' to…
- `create_directory` — Create a new directory or ensure a directory exists. Can create multiple nested directories in one operation. If the directory already exists, this operation will succeed silently. Perfect for setting up directory structures for projects…
- `edit_file` — Make line-based edits to a text file. Each edit replaces exact line sequences with new content. Returns a git-style diff showing the changes made. Only works within allowed directories.
- `move_file` — Move or rename files and directories. Can move files between directories and rename them in a single operation. If the destination exists, the operation will fail. Works across different directories and can be used for simple renaming wi…
- `write_file` — Create a new file or completely overwrite an existing file with new content. Use with caution as it will overwrite existing files without warning. Handles text content with proper encoding. Only works within allowed directories.

## For agents

This record is a snapshot. Live verdicts and the full registry:

- Check every server in your MCP config at once: `npx -y policylayer stack`
- Vet a server before you add it: install the mcp-precheck skill — `npx skills add https://policylayer.com` (skill text: https://policylayer.com/skill.md)
- Query the registry over MCP: endpoint `https://api.policylayer.com/mcp` — tools `check_mcp_server`, `check_mcp_stack`, `check_tool`, `search_registry`, `get_change_events`

---

Source: the PolicyLayer MCP registry — one continuously verified record per MCP server. Full record: https://policylayer.com/registry?q=filesystem · API: https://policylayer.com/registry/api · Recommended policies for every tool: https://policylayer.com/policies/filesystem
