Loomal

Filesystem MCP server in VS Code (GitHub Copilot) agent mode, beyond the workspace.

Copilot's agent mode can already edit files in your open workspace. Adding mcp-server-filesystem extends that reach to any directory you choose — with explicit, configurable scope in .vscode/mcp.json.

mcp-server-filesystem is an npm package from the ByteDance UI-TARS repo (github.com/bytedance/ui-tars-desktop, 36.3k stars) that exposes read, write, and search operations on local files as MCP tools. In VS Code, that lets Copilot's agent mode work on files outside your open workspace — a shared data directory, another repo, generated output folders — without you opening them.

VS Code reads MCP servers from mcp.json: project-scoped in .vscode/mcp.json, or user-scoped via the MCP: Add Server command in the Command Palette. Project scope is the better default here, because the directory you expose usually relates to the project you're in.

Add the server to .vscode/mcp.json

Create .vscode/mcp.json in your project (or run MCP: Add Server from the Command Palette and follow the prompts). VS Code's schema puts servers under a servers key — not mcpServers like most other clients — and supports variables like ${workspaceFolder} in args. The trailing path argument is the directory the server may access; the UI-TARS repo README documents the full argument list.

.vscode/mcp.json
{
  "servers": {
    "filesystem": {
      "type": "stdio",
      "command": "npx",
      "args": ["-y", "mcp-server-filesystem", "${workspaceFolder}"]
    }
  }
}

Start it and pick your tools

After saving, VS Code shows a Start link directly above the server entry in the file, and the server also appears in the Extensions view's MCP section. Click Start, then open Copilot Chat in agent mode and check the tools picker (the wrench icon) — the filesystem operations should be listed and toggleable.

Copilot asks for confirmation before running MCP tools by default. For a server that can write files, that's a feature; think before you blanket-approve.

When to use it over built-in editing

Copilot's native edit capability is scoped to your workspace and routed through the editor's diff view. The MCP server is the right tool when the agent needs raw filesystem reach: searching a directory VS Code doesn't have open, writing artifacts to an output folder outside the repo, or reading reference material from elsewhere on disk. Swap ${workspaceFolder} in the config for any absolute path to widen or narrow that reach.

Troubleshooting in VS Code

If the server never reaches the running state, open the Output panel and select the MCP server's channel — VS Code logs each server's stdout and stderr there, which is where npx failures (Node missing, package not found, bad directory argument) show up verbatim.

Other recurring issues: MCP support is disabled in settings (check chat.mcp.enabled), the JSON is valid but nested under mcpServers instead of servers so VS Code silently ignores it, or the server started before you edited the config — use the restart action in the MCP view rather than assuming the file is re-read live. A full window reload (Developer: Reload Window) clears anything stale.

The live listing

You can inspect mcp-server-filesystem's probed tool list on its Loomal marketplace listing at https://loomal.ai/marketplace/mcp-server-filesystem before adding it to your editor. Server maintainers can claim a listing like this to verify ownership and publish pricing for agent callers.

FAQ

How do I install the Filesystem server in VS Code with Copilot?

Add an entry under the servers key in .vscode/mcp.json with command npx and args ["-y", "mcp-server-filesystem", "<directory>"], or run MCP: Add Server from the Command Palette. Then click Start in the MCP view and the tools appear in Copilot's agent mode.

Where does VS Code store MCP configuration?

Two places: .vscode/mcp.json for project-scoped servers that travel with the repo, and user-level mcp.json managed through the MCP: Add Server command for servers you want in every workspace. Both use the same servers-keyed JSON schema.

Why doesn't the server show up in Copilot's tool picker?

Usually one of three things: the entry is under mcpServers instead of VS Code's servers key, MCP support is turned off via chat.mcp.enabled, or the server failed to launch — check its channel in the Output panel for the underlying npx error, then restart it from the MCP view.

Can the agent write outside my workspace with this server?

Only within directories you pass as arguments. ${workspaceFolder} confines it to the open project; an absolute path widens the scope to that path. Copilot also prompts for confirmation on tool calls by default, giving you a second gate on writes.

Browse more MCP servers for VS Code.

Every Loomal listing shows a live-probed tool list.

Browse the marketplace