October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PCOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
Claude Desktop

How to Connect to a Local MCP Server (Claude Desktop and VS Code)

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

To connect a local Model Context Protocol (MCP) server, configure your host application to launch the server as a local stdio process. Supply the executable, arguments, and—only when needed—environment variables, working directory, and access-limiting arguments. Then restart or start the entry in the client and verify its status and logs. Claude Desktop and VS Code use different configuration schemas, so never copy one client’s JSON into the other unchanged.

What a local MCP connection actually does

An MCP client does not normally “discover” a program merely because it is installed. Your desktop client or editor starts the server process and communicates with it over standard input and output (stdio). The configuration tells the host:

  • Which executable to run (for example, a runtime or package-manager command).
  • Which arguments to pass.
  • Which environment variables or environment file to load.
  • Which working directory to use.
  • What files, network resources, or other permissions the process can reach.

The server publisher’s installation instructions are authoritative for the command and arguments. The examples below show the shape of a configuration without inventing a package name.

Before you add the server

  • Install every runtime, package manager, and dependency required by the server.
  • Run the server’s documented command in a terminal once, if its documentation provides a manual test.
  • Record the full executable path if the command works in your shell but may not be on the graphical client’s PATH.
  • Decide which directories, credentials, and network access the server truly needs.
  • Review the server’s source or publisher before launching it. A local MCP server is executable code running with your operating-system user’s permissions, not an isolated sandbox.

Connect a local MCP server in Claude Desktop

Open the configuration editor

  1. Open Claude Desktop.
  2. Open Settings, select Developer, and choose Edit Config.
  3. On macOS, the documented file is ~/Library/Application Support/Claude/claude_desktop_config.json. On Windows, it is %APPDATA%Claudeclaude_desktop_config.json.

The MCP project’s Claude example uses a top-level mcpServers object. Add your server under a friendly key, preserving valid JSON:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
#1 Best Overall
Sale
Anker USB C Hub, 7in1 Multi-Port USB Adapter, 4K@60Hz USBC to HDMI Splitter
  • Sleek 7-in-1 USB-C Hub: Features an HDMI port, two USB-A 3.0 ports, and a USB-C data port, each providing 5Gbps transfer speeds. It also includes a USB-C PD input port for charging up to 100W and dual SD and TF card slots, all in a compact design.
  • Flawless 4K@60Hz Video with HDMI: Delivers exceptional clarity and smoothness with its 4K@60Hz HDMI port, making it ideal for high-definition presentations and entertainment. (Note: Only the HDMI port supports video projection; the USB-C port is for data transfer only.)
  • Double Up on Efficiency: The two USB-A 3.0 ports and a USB-C port support a fast 5Gbps data rate, significantly boosting your transfer speeds and improving productivity.
  • Fast and Reliable 85W Charging: Offers high-capacity, speedy charging for laptops up to 85W, so you spend less time tethered to an outlet and more time being productive.
  • What You Get: Anker USB-C Hub (7-in-1), welcome guide, 18-month warranty, and our friendly customer service.
{
  "mcpServers": {
    "example": {
      "command": "your-command",
      "args": ["your-server-arguments"]
    }
  }
}

Replace only the command and arguments documented by that server. Claude’s example does not use VS Code’s type property; adding fields from another client’s schema can prevent startup.

Limit filesystem examples to required folders

In the MCP guide’s filesystem example, directory arguments define which paths the example server is intended to expose. Pass only the folders needed for the task, such as a project directory rather than an entire home folder. The server can perform operations available to the user account that launches it.

Save, fully restart, and verify

  1. Save the JSON file.
  2. Completely quit Claude Desktop, not merely close a window, and start it again so the entry is loaded.
  3. Open the chat Connectors picker or return to Developer settings.
  4. Confirm the server is connected and inspect its tools.
  5. If it is missing or marked failed, open the available logs before changing multiple settings.

Use a desktop extension when available

Claude Desktop also documents a managed extension route: open Settings > Extensions to browse or install an extension, or use the advanced option for a custom .mcpb extension. This can be simpler than hand-editing JSON when the server is distributed in that format. Availability and labels can change between Claude Desktop releases.

Connect a local MCP server in VS Code

Choose workspace or user scope

VS Code supports adding a server through its MCP server interface or by editing a workspace file at .vscode/mcp.json. It also supports user-profile configuration for a server you want available across projects. Workspace scope keeps a project’s setup with that project; user scope avoids repeating a personal setup.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #2
Anker USB-C Hub, 5-in-1 USB Hub for Laptops, 4K HDMI Multiport Adapter
  • 5-in-1 USB-C Hub: Experience comprehensive connectivity featuring a Power Delivery input, two USB-A 2.0 ports, a USB-A 3.0 port, and an HDMI port. (Note: The USB-C power delivery input port is only for connecting an external wall charger to power your laptop and cannot power peripheral devices.)
  • 90W Pass-Through Charging: Achieve optimal charging with 90W pass-through power to your laptop, supported by a total input of 100W, with the hub reserving 10W for operational efficiency. (Note: Wall charger not included.)
  • Quick Data Transfers: Accelerate your productivity with rapid data transfers using a high-speed 5Gbps USB 3.0 port and two 480Mbps USB 2.0 ports.
  • 4K HDMI Display: Enhance your visual experience with a hub capable of delivering 4K resolution at 30Hz in both mirror and extend modes. Please note that this hub is compatible with MacBook (macOS 12 and newer), Windows 10 and 11, ChromeOS, and laptops equipped with DP Alt Mode and Power Delivery. Note: This device is not compatible with Linux.
  • What You Get: Anker USB-C Hub (5-in-1, 4K HDMI), welcome guide, 18-month warranty, and our friendly customer service.

Add a stdio entry

VS Code’s configuration reference uses a top-level servers object and identifies a local process with type: "stdio":

{
  "servers": {
    "example": {
      "type": "stdio",
      "command": "your-command",
      "args": ["your-server-arguments"]
    }
  }
}

The command must be on the system PATH visible to VS Code or specified with an absolute path. args is an array; keep each argument as its own JSON string instead of composing one shell command line.

Supply environment, working directory, and secrets carefully

The VS Code reference documents optional env, envFile, and cwd settings. Use cwd when the server expects to resolve files relative to a project. Use envFile or the client’s secret-input mechanism for credentials rather than committing tokens to a shared .vscode/mcp.json. Keep an env block limited to non-sensitive values that genuinely belong in the configuration.

Start and inspect the entry

  1. Open the MCP server interface in VS Code.
  2. Add the entry through the interface or save the appropriate workspace/user configuration.
  3. Use the interface’s start or restart control.
  4. Check the server status and output/log view.
  5. Call a simple tool only after the process reports a healthy connection.

VS Code also describes network connections, but a network transport is appropriate only when both the selected client and server document support it. For a program running on your computer, stdio is the usual local route.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #3
Anker USB C Hub, 5-in-1 USBC to HDMI Splitter with 4K Display
  • 5-in-1 Connectivity: Equipped with a 4K HDMI port, a 5 Gbps USB-C data port, two 5 Gbps USB-A ports, and a USB C 100W PD-IN port. Note: The USB C 100W PD-IN port supports only charging and does not support data transfer devices such as headphones or speakers.
  • Powerful Pass-Through Charging: Supports up to 85W pass-through charging so you can power up your laptop while you use the hub. Note: Pass-through charging requires a charger (not included). Note: To achieve full power for iPad, we recommend using a 45W wall charger.
  • Transfer Files in Seconds: Move files to and from your laptop at speeds of up to 5 Gbps via the USB-C and USB-A data ports. Note: The USB C 5Gbps Data port does not support video output.
  • HD Display: Connect to the HDMI port to stream or mirror content to an external monitor in resolutions of up to 4K@30Hz. Note: The USB-C ports do not support video output.
  • What You Get: Anker 332 USB-C Hub (5-in-1), welcome guide, our worry-free 18-month warranty, and friendly customer service.

How to choose a configuration route

Decision Claude Desktop VS Code
Primary local schema mcpServers; command and args in the Claude configuration file servers; local entries normally include type: "stdio"
Typical location Developer settings, then the platform-specific Claude JSON file Workspace .vscode/mcp.json or user-profile configuration
Lifecycle controls Quit and relaunch; status and logs in Connectors or Developer settings MCP interface start/restart controls and output/log views
Managed installation Desktop extensions, including custom .mcpb files when available Install and manage through the MCP interface or configuration
Best scope for project-only access Restrict server arguments to required directories Use workspace configuration and a project-specific cwd or environment

Security and access boundaries

Microsoft’s VS Code documentation warns that local MCP servers can run arbitrary code. Treat a server like any other executable you install:

  • Verify the publisher and inspect the source or package.
  • Read every argument before granting it.
  • Expose the smallest directory set that satisfies the task.
  • Do not place API keys in a workspace file that will be shared or committed.
  • Check the operating-system account, network access, and inherited permissions used by the client.
  • Stop and remove the entry if its behavior or requested access is unexpected.

Troubleshooting: why your local MCP server is not connecting

The process never starts

Cause: The executable is misspelled, unavailable to the GUI process, or a required runtime is missing. Fix: run the documented command in a terminal, then use an absolute executable path in the client configuration and verify the runtime/package manager installation.

The entry is present but disappears after editing

Cause: Invalid JSON, the wrong top-level key, or a schema copied from another client. Fix: validate commas, quotes, and braces; use mcpServers for Claude Desktop and servers with the documented stdio fields for VS Code.

Windows paths or variables fail

Cause: Backslashes were not escaped, a directory does not exist, or the client cannot expand an environment variable. Fix: write Windows backslashes as \ in JSON, confirm the path is readable by the client user, and follow Claude’s targeted guidance to expand APPDATA explicitly if that variable is not resolving.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #4
Sale
UGREEN USB C Hub 5 in 1 Multiport USB Adapter 4K HDMI, 100W Power Delivery
  • 5 in 1 Connectivity: The USB C Multiport Adapter is equipped with a 4K HDMI port, a 100W USB C PD port, a 5 Gbps USB A data port, and two 480 Mbps USB A ports

Arguments or directories are rejected

Cause: An argument is in the wrong position, contains an unquoted space, or points to an inaccessible location. Fix: compare each argument with the server publisher’s instructions, keep one argument per array item, and test with the smallest existing directory.

The server connects, but a tool is missing

Cause: The server and client expose different capabilities, or the server failed during initialization. Fix: inspect the client and server logs, read the server’s capability documentation, and confirm that the installed version supports the expected tool or resource.

Changes have no effect

Cause: The host has not reloaded its configuration. Fix: fully restart Claude Desktop; in VS Code, use the MCP interface’s restart control or reload the window when prompted.

Access is broader than intended

Cause: A filesystem server was given a home directory, broad environment, or powerful credentials. Fix: stop it, remove unnecessary arguments and variables, reduce directory scope, and restart only after reviewing the resulting permissions.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Best Value
Anker USB C Hub, USB Extender, 4-in-1 USB Splitter, Computer Accessories
  • Ultra-Fast Data Transfers: Experience the power of 5Gbps transfer speeds with this USB hub and sync data in seconds, making file transfers a breeze.
  • Long Cable, Endless Convenience: Say goodbye to short and restrictive cables. This USB hub comes with a 2 ft long cable, giving you the freedom to connect your devices exactly where you need them.
  • Sleek and Compact: Measuring just 4.2 × 1.2 × 0.4 inches, carry the USB hub in your pocket or laptop bag and connect effortlessly wherever you go.
  • Instant Connectivity: Anker USB-C data hub offers a true plug-and-play experience, instantly connecting your devices and enabling seamless file transfers.
  • What You Get: 2ft Anker USB-C Data Hub (4-in-1, 5Gbps) , welcome guide, our worry-free 18-month warranty, and friendly customer service.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Or skip the browser setup

If your local MCP workflow needs reliable website screenshots, ScreenshotNeo provides an MCP server for Claude, Cursor, and other MCP clients. It removes cookie and consent banners, newsletter popups, and chat widgets before capture; bot checks, blank pages, failed loads, timeouts, and cache hits are not billed, and each response identifies the page verdict and billing status. You can still call its HTTP API directly:

API documentation

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp
import requests
r = requests.get("https://api.screenshotneo.com/v1/shot", params={"access_key": "YOUR_API_KEY", "url": "https://stripe.com"}, timeout=90)
open("shot.webp", "wb").write(r.content)
const q = new URLSearchParams({ access_key: 'YOUR_API_KEY', url: 'https://stripe.com' });
const res = await fetch(`https://api.screenshotneo.com/v1/shot?${q}`);

ScreenshotNeo supports full-page and element captures, device presets, custom viewports, retina scale, PDF output, HTML/CSS rendering, custom JavaScript and CSS, waits, request blocking, cookies and headers, geolocation, transparent backgrounds, resizing, chosen cache TTLs, signed links, asynchronous webhooks, bulk capture, usage data, and an OpenAPI specification. Its parameter names are compatible with those used by other screenshot APIs, which can simplify migration.

The Free plan includes 1,000 screenshots per month with no card. Paid plans start at $5 for 3,000 screenshots; every feature is included on every plan. Create a free ScreenshotNeo account to get started.

Operational notes for dependable connections

  • Use deterministic paths: absolute executable and project paths reduce differences between a terminal shell and a GUI-launched process.
  • Keep startup lightweight: avoid loading unnecessary tools or scanning broad directories during initialization.
  • Separate configuration by scope: user settings suit personal utilities; workspace settings make project requirements reviewable.
  • Read logs before retrying: repeated restarts can hide the original parse or permission error.
  • Review changes after upgrades: client menus, configuration fields, and server capabilities can change; check the current documentation for your installed release.

Frequently Asked Questions

Can I use the same MCP JSON in Claude Desktop and VS Code?

No. Claude Desktop’s documented local configuration uses mcpServers, while VS Code uses servers and a stdio type. Adapt the command and arguments to the host’s schema.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Does a local MCP server run in a sandbox?

Not by default. It runs as a local process with the permissions of the account that launched it, so directory, credential, and network access must be reviewed.

Should I choose workspace or user configuration in VS Code?

Choose workspace scope for a project-specific server that teammates can review, and user scope for a personal server you want available across projects.

What should I do if the client shows a server but no tools?

Check both client and server logs, then verify the server’s documented capabilities and installed version. A configured entry does not guarantee successful initialization or a particular tool set.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Read next

Recommended PC Tool
Recommended PC Tool
Windows Errors? Fix Them Before They SpreadFree repair scan
Crashes, No Sound, or Screen Glitches?Free driver scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.