Install DevSpace and cloudflared
Install DevSpace on the development machine and verify that both tools are available in the terminal.
npm install -g @waishnav/devspace
devspace doctor
cloudflared --version
TECHNICAL GUIDE
Connect ChatGPT to a local development environment so it can inspect projects, edit files, and run development commands through a controlled MCP interface.
MCP stands for Model Context Protocol. It is a standard interface that lets an AI client discover and call external tools. Instead of only discussing code in chat, the model can use approved tools to work with files, repositories, terminals, databases, and other services.
DevSpace is an MCP server designed for software development. It runs on a local machine and exposes development capabilities such as reading files, editing code, inspecting Git repositories, and running shell commands.
127.0.0.1:7676. ChatGPT runs remotely, so a secure HTTPS endpoint is needed. Cloudflare Tunnel can expose the local MCP service without opening a router port.
Install DevSpace on the development machine and verify that both tools are available in the terminal.
npm install -g @waishnav/devspace
devspace doctor
cloudflared --version
Create a named Cloudflare Tunnel and run the generated service-install command with administrator privileges. This keeps the tunnel running as a Windows service.
cloudflared.exe service install <TUNNEL_TOKEN>
Route a dedicated subdomain to the local DevSpace service. A typical configuration is:
devspace.example.comhttp://127.0.0.1:7676leave emptyInitialize DevSpace, choose the directories it is allowed to access, and set the public base URL. Keep the allowed roots as narrow as possible.
devspace init
devspace config set publicBaseUrl https://devspace.example.com
The public base URL does not include /mcp.
devspace serve
The local endpoint is typically:
http://127.0.0.1:7676/mcp
Create a custom MCP app in ChatGPT and use the public MCP endpoint:
https://devspace.example.com/mcp
Choose OAuth authentication if required. On the first connection, DevSpace may ask for the owner password created during initialization.
Once connected, ChatGPT can call DevSpace tools when a task requires access to the local project. A good workflow is to begin with read-only inspection, then allow edits only after the project and requested change are clear.
“Open this project and explain its directory structure. Do not modify any files.”
“Run the test suite, identify the failing test, and explain the likely cause before changing anything.”
“Fix the issue, rerun the tests, and summarize the changes shown by Git diff.”
DevSpace can expose powerful development tools, so it should be treated as remote access to a development machine. Restrict the accessible directories, keep authentication enabled, and avoid exposing folders that contain SSH keys, API credentials, browser profiles, or unrelated personal files.