MCP in VS Code

VS Code supports MCP servers as AI customization components. Servers can provide tools, resources, prompts, and interactive MCP Apps.

Configuration

Workspace configuration commonly lives in .vscode/mcp.json; user-profile configuration is also supported. VS Code provides guided add/manage commands and a server gallery.

Trust and sandboxing

VS Code prompts for trust before starting new MCP server configurations and supports sandboxing for local servers on supported platforms, with explicit filesystem/network permissions.

Tool selection

Users can enable/disable individual tools. Reducing the available tool set improves context use, relevance, and credit consumption.

Do not hardcode secrets

Use input variables, environment files, or secret mechanisms rather than committing API keys into workspace configuration.

Reference

VS Code MCP servers