vscode-as
Expose VSCode features such as file viewing and editing as MCP, enabling advanced AI-assisted coding directly from tools like Claude Desktop
claude mcp add --transport stdio acomagu-vscode-as-mcp-server npx vscode-as-mcp-server
How to use
This MCP server turns your running VSCode instance into an MCP-accessible service. It exposes a collection of built-in tools that an MCP client (for example, Claude Desktop or another LLM client) can invoke to interact with your editor and workspace. Available tools include executing commands in VSCode's integrated terminal, retrieving current diagnostics, focusing editor locations, managing debug sessions, performing file and directory operations, listing VSCode commands, and opening URLs in the built-in preview browser. To use it, install the vscode-as-mcp-server extension from the marketplace, then start the MCP server on the client side (commonly via an MCP runner or your MCP client configuration). The README example shows wiring the server with a client by pointing to an MCP server named “vscode” and using npx vscode-as-mcp-server for the command. Once the server is running, configure your MCP client to connect to this server and invoke the desired built-in tool by name, e.g., execute_command to run terminal commands or code_checker to fetch diagnostics. You can switch between multiple VSCode windows/instances (multi-instance switching) and leverage the relay functionality to expose local MCP tools to external clients if needed. The capabilities enable dynamic code edits, real-time feedback, and interactive workflows directly inside VSCode.
How to install
Prerequisites:
- VSCode installed
- Node.js and npm installed
- Access to install the vscode-as-mcp-server extension from the VSCode Marketplace
Installation steps:
-
Install VSCode and ensure it runs with the required permissions.
-
Install the MCP server extension from the Marketplace: vscode-as-mcp-server (acomagu.vscode-as-mcp-server).
-
Ensure you have the MCP client installed or available (e.g., Claude Desktop) and prepared to configure an MCP server endpoint.
-
Start the MCP server using the command shown in the README (example):
npx vscode-as-mcp-server
-
In your MCP client configuration, register the server endpoint. For example, in claude_desktop_config.json, add:
{ "mcpServers": { "vscode": { "command": "npx", "args": ["vscode-as-mcp-server"] } } }
-
Verify the server status in VSCode’s bottom-right status bar (Server running indicator or click to start).
Optional:
- If you plan to expose tools externally, review the Relay Functionality notes and adjust security settings accordingly.
- Configure specific environment variables as needed for your workflow (see additional_notes).
Additional notes
Tips and notes:
- The server uses npx to run vscode-as-mcp-server, so ensure npm is available in your PATH.
- You can run multiple VSCode windows; the server supports multi-instance switching via the status bar item.
- The Relay feature is experimental and can expose built-in MCP servers from other extensions; use caution when exposing tools externally.
- If you encounter issues starting the server, verify that VSCode is running and that the MCP client is configured to reach the correct endpoint. Check the bottom-right status bar for server status indicators.
- Tools available include execute_command, code_checker, focus_editor, a suite of debug session controls, text_editor operations, list_directory, get_terminal_output, list_vscode_commands, execute_vscode_command, and preview_url.
Related MCP Servers
iterm
A Model Context Protocol server that executes commands in the current iTerm session - useful for REPL and CLI assistance
mcp
Octopus Deploy Official MCP Server
furi
CLI & API for MCP management
editor
MCP Server for Phaser Editor
DoorDash
MCP server from JordanDalton/DoorDash-MCP-Server
mcp
MCP сервер для автоматического создания и развертывания приложений в Timeweb Cloud