I have installed the MCP_Server integration in my HA test environment and following the detailed instructions by its author.
Whatever I try, I cannot get Claude or Cursor to connect to the MCP_Server. I have checked, double-checked and tripple-checked the json config files but no luck.
Using curl, I CAN connect. Using Postman, I can also connect. So my prelim conclusion is that my server is configured ok, my long-lived security token is ok
I cannot find any logging in Cursor, just the red dot in my MCP config section.
Claude says âCould not attach to MCP server Home Assistantâ (as per the documentation, that would mean it can actually find my mcp-proxy, but mcp_proxy does not call the MCP server properly). In Claude logging, I see this:
2025-04-06T21:32:39.111Z [Home Assistant] [info] Initializing server...
2025-04-06T21:32:39.185Z [Home Assistant] [info] Server started and connected successfully
2025-04-06T21:32:39.186Z [Home Assistant] [info] Message from client: {"method":"initialize","params":{"protocolVersion":"2024-11-05","capabilities":{},"clientInfo":{"name":"claude-ai","version":"0.1.0"}},"jsonrpc":"2.0","id":0}
could not start the proxy Error: spawn http://192.168.[xxx].[yyy]:8123/mcp_server/sse ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:285:19)
at onErrorNT (node:internal/child_process:483:16)
at process.processTicksAndRejections (node:internal/process/task_queues:90:21) {
errno: -2,
code: 'ENOENT',
syscall: 'spawn http://192.168.[xxx].[yyy]:8123/mcp_server/sse',
path: 'http://192.168.[xxx].[yyy]:8123/mcp_server/sse',
spawnargs: []
}
For Claude:
When I follow the configuration as per the documentation, I get the following error:
2025-04-06T20:30:36.737Z [Home Assistant] [info] Initializing server...
2025-04-06T20:30:36.817Z [Home Assistant] [info] Server started and connected successfully
2025-04-06T20:30:37.089Z [Home Assistant] [info] Message from client: {"method":"initialize","params":{"protocolVersion":"2024-11-05","capabilities":{},"clientInfo":{"name":"claude-ai","version":"0.1.0"}},"jsonrpc":"2.0","id":0}
mcp-proxy <command> [args...]
Run a command with MCP arguments
Positionals:
command The command to run [string]
args The arguments to pass to the command [string]
Options:
--version Show version number [boolean]
--debug Enable debug logging [boolean] [default: false]
--endpoint The endpoint to listen on for SSE [string] [default: "/sse"]
--port The port to listen on for SSE [number] [default: 8080]
--help Show help [boolean]
Not enough non-option arguments: got 0, need at least 1
When I then change it and give the (apparently missing for mcp-proxy) URL as an argument:
Turns out that I picked up âanotherâ mcp-proxy from somewhere, which was causing the issue.
After removing the incorrect âmcp-proxyâ, installed âuvâ on my Mac and the installing the mcp-proxy as per the mcp-proxy documentation (at the time of this writing: âuv tool install mcp-proxyâ), I could connect to Cursor to my HA serverâs MCP Server.
Still working out why Claude does not want to connect yet. Once Iâve resolved that, Iâll post it here in case anyone ever runs into this later.
Many thanks for your efforts into getting this mcp-server integrated into HA, Allen. Much appreciated!
Problem: Claude Desktop canât start the server: ENOENT code in the logs
Solution: Try to use the full path to the binary. To do so, open a terminal and run the command where mcp-proxy (macOS, Linux) or where.exe mcp-proxy (Windows). Then, use the output path as a value for âcommandâ attribute: