Replies: 3 comments
|
Yes, this works well. Each ha-mcp instance connects to exactly one Home Assistant, so for two homes you register two separate MCP servers in {
"mcpServers": {
"Home Assistant (Local)": {
"command": "uvx",
"args": ["ha-mcp@latest"],
"env": {
"HOMEASSISTANT_URL": "http://homeassistant.local:8123",
"HOMEASSISTANT_TOKEN": "<long-lived token from the LOCAL home>",
"MCP_SERVER_NAME": "ha-local",
"HA_MCP_CONFIG_DIR": "/Users/youruser/.ha-mcp/local"
}
},
"Home Assistant (Remote)": {
"command": "uvx",
"args": ["ha-mcp@latest"],
"env": {
"HOMEASSISTANT_URL": "https://your-vpn-tunnel-host:8123",
"HOMEASSISTANT_TOKEN": "<long-lived token from the REMOTE home>",
"MCP_SERVER_NAME": "ha-remote",
"HA_MCP_CONFIG_DIR": "/Users/youruser/.ha-mcp/remote"
}
}
}
}Notes:
For the remote one, make sure |
|
You can definitely set up more than one like SealKan says but I would recommend against leaving both active at the same time in your AI because it'll get easily confused between the two and can cause some context window issues. I'm not sure if Claude Desktop allows this, but Claude.ai and Claude code both allow disabling MCP servers on demand, so just make sure to disable the one you don't need at the time before you start a session. |
|
Following up on @kingpanther13's point about disabling the unused server — I checked the current behavior and it differs by client, so worth being precise for anyone landing here:
So @kingpanther13's advice holds — just with a caveat on the mechanics: on Claude Desktop it's a config edit + restart rather than a live toggle, so for two homes the cleanest options are either the |
Uh oh!
There was an error while loading. Please reload this page.
One local HAOS and one remote HAOS via vpn tunnel run both homes. How and can I add a second HOMEASSISTANT_URL and token to the claude_desktop_config.json. Is this possible, and how would I switch between them or use both for comparing settings and frontends? Pretty new to this and any input or direction would be great.
All reactions