Skip to main content
Glama
adrighem

Domoticz MCP Server

by adrighem

Domoticz MCP Server

A Model Context Protocol (MCP) server for integrating with the Domoticz home automation system. This server provides tools to AI assistants (like Claude, Gemini, etc.) to view and control your smart home devices, scenes, user variables, and more.

Features

  • Device Control: Toggle switches, set states (On/Off), set dimmer levels, set thermostat temperatures, and control blinds.

  • Device Information: Retrieve states for all devices or specific ones.

  • Rooms and Scenes: List rooms (Room Plans), get devices within rooms, and control scenes/groups.

  • User Variables: Read, add, update, and delete Domoticz user variables.

  • History and Logs: Access device history graphs and text/light logs.

  • System Information: Get Domoticz instance version and internal event scripts/rules.

Prerequisites

  • Python 3.10 or higher

  • A running Domoticz instance

  • Network access to the Domoticz API

Installation

Using uv (Recommended)

If you use uv, you can run the server directly from the source repository without installing it globally:

uv run --directory /path/to/domoticz-mcp domoticz-mcp

Standard Python Installation (Linux, macOS, Windows)

  1. Clone or download this repository.

  2. Navigate to the project directory.

  3. Install the package using pip:

pip install .

This will install the domoticz-mcp command-line tool.

Configuration

The server requires configuration to connect to your Domoticz instance. These are provided as environment variables.

  • DOMOTICZ_URL: The base URL of your Domoticz instance (e.g., http://192.168.1.100:8080). Defaults to https://xmpp.vanadrighem.eu/domoticz if not set.

  • DOMOTICZ_USERNAME: (Optional) Your Domoticz username if basic authentication is enabled.

  • DOMOTICZ_PASSWORD: (Optional) Your Domoticz password.

MCP Client Configuration

Gemini CLI

Add the following to your ~/.gemini/settings.json under the mcp.servers object:

{
  "mcp": {
    "servers": {
      "domoticz": {
        "command": "uv",
        "args": [
          "--directory",
          "/path/to/domoticz-mcp",
          "run",
          "domoticz-mcp"
        ],
        "env": {
          "DOMOTICZ_URL": "http://192.168.1.x:8080",
          "DOMOTICZ_USERNAME": "your_username",
          "DOMOTICZ_PASSWORD": "your_password"
        }
      }
    }
  }
}

Claude Desktop

Add the following to your claude_desktop_config.json:

{
  "mcpServers": {
    "domoticz": {
      "command": "uv",
      "args": [
        "--directory",
        "/path/to/domoticz-mcp",
        "run",
        "domoticz-mcp"
      ],
      "env": {
        "DOMOTICZ_URL": "http://192.168.1.x:8080",
        "DOMOTICZ_USERNAME": "your_username",
        "DOMOTICZ_PASSWORD": "your_password"
      }
    }
  }
}

If you installed it globally via pip, you can use the command directly:

{
  "mcpServers": {
    "domoticz": {
      "command": "domoticz-mcp",
      "args": [],
      "env": {
        "DOMOTICZ_URL": "http://192.168.1.x:8080",
        "DOMOTICZ_USERNAME": "your_username",
        "DOMOTICZ_PASSWORD": "your_password"
      }
    }
  }
}

Other MCP Clients

For other clients that support the Model Context Protocol, simply configure them to run the domoticz-mcp binary or the uv run command with the appropriate environment variables.

License

This project is licensed under the GNU General Public License v3.0 (GPLv3). See the LICENSE file for details.

-
security - not tested
-
license - not tested
-
quality - not tested

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/adrighem/domoticz-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server