Skip to content

How-ToGPU

How to Give Local AI Models Tools in LM Studio Using MCP Servers

LM Studio 0.3.17 and later can connect local AI models to MCP servers, letting a model read files, search or call other tools. Add servers by editing mcp.json from the Program tab, start with the official filesystem server in read-only mode on a test folder, and keep tool-call confirmations on, because LM Studio warns servers can run code and access files. Forge PC has not tested specific servers.

By , Editorial team

4 min read

How to Give Local AI Models Tools in LM Studio Using MCP Servers

A local language model on its own can only answer from what it learned in training and what you paste into the chat. The Model Context Protocol (MCP) changes that. It's an open standard for connecting AI applications to outside data and tools, which the MCP project likens to a USB-C port for AI apps. Since version 0.3.17, LM Studio can act as an MCP host, so the model running on your own PC can call those tools.

Forge PC has not tested specific MCP servers with specific models. This guide is based on LM Studio's MCP documentation and release notes and the official MCP filesystem server documentation, checked on 15 November 2026.

What you need

  • LM Studio 0.3.17 or later. LM Studio says MCP support (local and remote servers) arrived in 0.3.17. If you're new to the app, start with our guide to running AI models with Ollama or LM Studio.

  • A model that supports tool use. Tools only help if the model knows how to call them. LM Studio's model pages show whether a model supports tool use; Qwen3.8, for example, is listed with tool use, vision and reasoning support. Our guide to choosing models in LM Studio covers sizing a model to your graphics card.

  • For local servers launched with npx, Node.js. LM Studio notes that if a server uses a command such as npx or uvx, that program must be installed and on your system PATH.

Step 1: Open LM Studio's mcp.json

  1. Open LM Studio and switch to the Program tab in the right-hand sidebar.

  2. Click Install > Edit mcp.json. This opens the file in LM Studio's built-in editor.

LM Studio stores the file at %USERPROFILE%/.lmstudio/mcp.json on Windows (and ~/.lmstudio/mcp.json on macOS and Linux), but recommends using the in-app editor. The format follows Cursor's mcp.json notation, so examples written for other MCP apps usually need little or no change.

Some MCP servers also offer an Add to LM Studio button, which is a deeplink that adds the entry for you.

Step 2: Add a safe first server

The official MCP filesystem server is a good first test because you control exactly which folders it can see. Its documentation gives this layout for Windows, which uses cmd /c to launch npx:

{
  "mcpServers": {
    "filesystem": {
      "command": "cmd",
      "args": ["/c", "npx", "-y", "@modelcontextprotocol/server-filesystem", "C:\\Users\\you\\Documents\\ai-notes"]
    }
  }
}

Replace the folder with one you're happy for the model to access; you can list more than one. The filesystem server can create, edit, move and delete files inside those folders, so start with a test folder. Its documentation also describes a --read-only option that hides every tool that writes, which is the safer way to try it:

"args": ["/c", "npx", "-y", "@modelcontextprotocol/server-filesystem", "--read-only", "C:\\Users\\you\\Documents\\ai-notes"]

LM Studio's documentation adds one formatting tip: when pasting a server into an existing file, copy only what goes inside "mcpServers": { ... }, so you don't end up with two mcpServers blocks.

Step 3: Save and let LM Studio load it

When you save mcp.json, LM Studio loads the servers in it automatically and starts a separate process for each one. Load a tool-capable model and start a new chat.

Step 4: Approve tool calls

When the model wants to use a tool, LM Studio shows a confirmation dialog with the arguments it wants to pass. You can edit those arguments before running it, and choose to allow the tool once or always. If you pick "always", LM Studio won't ask again for that tool, so keep confirmation on for anything that writes, deletes or sends data.

Adding a remote server

Remote servers use a URL instead of a command. LM Studio's example is Hugging Face's MCP server, which provides tools such as model and dataset search:

{
  "mcpServers": {
    "hf-mcp-server": {
      "url": "https://huggingface.co/mcp",
      "headers": { "Authorization": "Bearer <YOUR_HF_TOKEN>" }
    }
  }
}

You replace <YOUR_HF_TOKEN> with your own Hugging Face token. Treat that file like a password store: anything you put in a header is saved in plain text in mcp.json.

Staying safe and keeping it fast

  • Only install servers you trust. LM Studio warns that some MCP servers can run arbitrary code, access your local files and use your network connection.

  • Watch your context window. LM Studio cautions that servers designed for cloud models such as Claude, ChatGPT or Gemini can use a lot of tokens, which can bog down a local model and cause frequent context overflows. Our LLM speed-up guide and GGUF quantisation explainer explain the memory trade-off of a bigger context.

  • Mind your VRAM. Tool results are added to the conversation, so long sessions need more memory. Our guide to checking VRAM usage helps you see when a model is spilling into system RAM.

If you'd rather call LM Studio from other apps instead, see our guide to the LM Studio local server.

Our verdict

LM Studio's MCP support turns a local model into something that can act on your files and other services: edit mcp.json from the Program tab, add a server, save, and approve each tool call. Start with the official filesystem server in read-only mode on a test folder, keep tool confirmations switched on for anything that writes or sends data, and only install servers from sources you trust, because LM Studio warns they can run code and access your files. Forge PC has not tested specific servers; steps follow LM Studio's and the MCP project's documentation.

The bottom line

LM Studio's MCP support turns a local model into something that can act on your files and other services: edit mcp.json from the Program tab, add a server, save, and approve each tool call. Start with the official filesystem server in read-only mode on a test folder, keep tool confirmations switched on for anything that writes or sends data, and only install servers from sources you trust, because LM Studio warns they can run code and access your files. Forge PC has not tested specific servers; steps follow LM Studio's and the MCP project's documentation.

Sources

  1. 01LM Studio, Use MCP Servers
  2. 02LM Studio, LM Studio 0.3.17 release notes (MCP support)
  3. 03LM Studio, Qwen3.8 model page
  4. 04Model Context Protocol, What is the Model Context Protocol?
  5. 05Model Context Protocol, Filesystem MCP server

About the author

Forge PC Staff

Editorial team

The shared byline for articles researched, written and edited by the Forge PC editorial team. How we source, check and correct our work is set out in our editorial policy.

More from Forge PC Staff

Read next

How to Enable AMD Fluid Motion Frames (AFMF 2.1) on a Radeon Graphics Card

How-To

How to Enable AMD Fluid Motion Frames (AFMF 2.1) on a Radeon Graphics Card

To enable AMD Fluid Motion Frames, install Adrenalin 25.3.1 or newer, then select the HYPR-RX profile (RX 7000 and newer) or turn on AMD Fluid Motion Frames under Gaming > Graphics, globally or per game. AFMF 2.1 works on RX 6000 cards and newer in DirectX 11, DirectX 12, Vulkan and OpenGL games, with VSync off; RX 6000 cards need exclusive full screen.

Forge PC Staff2 min

How to Use System Restore in Windows 11: Turn It On, Create a Restore Point and Roll Back

How-To

How to Use System Restore in Windows 11: Turn It On, Create a Restore Point and Roll Back

Microsoft says System Protection isn't on by default. Search for Create a restore point, select your C: drive, choose Configure and turn it on, then create a restore point before installing drivers or tools. To roll back, run rstrui.exe, or use Troubleshoot > Advanced options > System Restore in Windows RE. Personal files aren't affected, but it isn't a backup.

Forge PC Staff3 min

How to Use Live Captions and Translation in Windows 11

How-To

How to Use Live Captions and Translation in Windows 11

Press Windows + Ctrl + L to turn on live captions in Windows 11 22H2 or later, download the language files, then dock or float the captions and pick a style. Captions are generated on the device and work offline. On a Copilot+ PC with 24H2 or later, live captions can translate from over 40 languages into English and 27 into Chinese (Simplified).

Forge PC Staff3 min

How to Manage Ollama Models: List, Remove and Move Them to Another Drive

How-To

How to Manage Ollama Models: List, Remove and Move Them to Another Drive

Run ollama ls to list your models, ollama ps to see what's loaded, ollama stop to unload one and ollama rm to delete it. On Windows, models are stored in C:\Users\%username%\.ollama\models; to move them, quit Ollama, set an OLLAMA_MODELS user environment variable to a folder on a bigger drive and restart Ollama.

Forge PC Staff3 min