Domoticz MCP Server

Domoticz MCP Server

Integrates AI assistants with the Domoticz home automation system to monitor and control smart home devices, scenes, and variables. It enables users to manage device states, room configurations, and system logs through the Model Context Protocol.

Category
Visit Server

README

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.

Authentication Options

You can authenticate the MCP server with Domoticz using either Basic Auth or an OAuth/API Token (Recommended).

Option 1: OAuth / API Token (Recommended)

This approach uses a Bearer token and is generally more secure, as you can revoke the token at any time without changing your password.

  1. In the Domoticz UI, go to Setup -> Settings -> Security.
  2. Look for the API Tokens or OAuth2 section and generate a new token for the MCP Server.
  3. Configure the following environment variable:
    • DOMOTICZ_OAUTH_TOKEN: The token string you generated.

Note: If you use a token, you can safely disable "Allow Basic-Auth authentication over plain HTTP" in the Domoticz security settings.

Option 2: Basic Auth

If you prefer traditional username and password authentication:

  1. In the Domoticz UI, go to Setup -> Settings -> Security.
  2. Ensure "Allow Basic-Auth authentication over plain HTTP" is enabled (if you are not using HTTPS).
  3. Configure the following environment variables:
    • DOMOTICZ_USERNAME: Your Domoticz username.
    • DOMOTICZ_PASSWORD: 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_OAUTH_TOKEN": "your_token_here",
          "DOMOTICZ_USERNAME": "your_username_if_using_basic_auth",
          "DOMOTICZ_PASSWORD": "your_password_if_using_basic_auth"
        }
      }
    }
  }
}

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_OAUTH_TOKEN": "your_token_here",
        "DOMOTICZ_USERNAME": "your_username_if_using_basic_auth",
        "DOMOTICZ_PASSWORD": "your_password_if_using_basic_auth"
      }
    }
  }
}

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_OAUTH_TOKEN": "your_token_here",
        "DOMOTICZ_USERNAME": "your_username_if_using_basic_auth",
        "DOMOTICZ_PASSWORD": "your_password_if_using_basic_auth"
      }
    }
  }
}

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.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured