Home Assistant MCP
Provides tools for interacting with smart home devices through Home Assistant, enabling verification of API status, retrieving entity states, and calling services to control devices like lights.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Home Assistant MCP turn on the living room lights"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Home Assistant MCP
This is an MCP (Model Context Protocol) server that provides tools for integration with Home Assistant, allowing AI assistants to interact with smart home devices.
Setup
Installing via Smithery
To install Home Assistant Integration for Claude Desktop automatically via Smithery:
npx -y @smithery/cli install @guilhermelirio/homeassistant-mpc --client claudeManual Installation
Install dependencies:
npm installConfigure environment variables:
Obtain a Long-Lived Access Token from your Home Assistant
Configure the environment variables in a
.envfile at the project root:
HOME_ASSISTANT_URL=http://your-home-assistant:8123
HOME_ASSISTANT_TOKEN=your_token_hereRelated MCP server: Home Assistant MCP Server
Starting the server
npm startFor development:
npm run devAvailable Tools
Home Assistant API Verification
homeassistant_api: Verifies if the Home Assistant API is online
Parameters: none
Example:
homeassistant_api()
Get Entity State
homeassistant_get_state: Gets the current state of a Home Assistant entity
Parameters:
entity_id(entity ID)Example:
homeassistant_get_state("light.living_room")
Call Services
homeassistant_call_service: Calls a service for a Home Assistant entity
Parameters:
entity_id(entity ID)domain(service domain)service(service to call)
Example:
homeassistant_call_service("light.living_room", "light", "turn_on")
Development
This project uses TypeScript and the MCP SDK library to create tools that can be accessed by language models such as Claude, GPT, etc.
To add new tools:
Create a module in
src/tools/[category]Implement your tools following the existing pattern
Register the module in
src/index.ts
Contributions
Contributions are welcome! Feel free to open issues or submit pull requests.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Available Tools
3 toolshomeassistant_apiB
Verify if the Home Assistant API is online
Inputs: no named parameters.
homeassistant_call_serviceC
Call a service of a Home Assistant entity
Inputs: domain (required), entity_id (required), service (required).
homeassistant_get_stateC
Get the state of a Home Assistant entity
Inputs: entity_id (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 3 tools
Each tool has a clearly distinct purpose: one checks API status, one calls services, and one retrieves entity states. There is no overlap in functionality, making it easy for an agent to select the correct tool without confusion.
All tool names follow a consistent snake_case pattern with a 'homeassistant_' prefix and descriptive verb_noun combinations (api, call_service, get_state). This uniformity enhances readability and predictability.
With only 3 tools, the set feels thin for a Home Assistant integration, which typically involves more operations like listing entities, setting states, or handling events. While the tools cover basic needs, the scope could be expanded for better coverage.
The tools provide core functionality (API check, service calls, state retrieval) but lack operations like listing entities, updating states, or handling events. This creates minor gaps that agents might need to work around, though basic workflows are supported.
Maintenance
Related MCP Connectors
Home energy for AI assistants: live Power flow, Energy history, solar forecast, and device control.
Control your existing Philips lights, Sonos speakers, Roborock vacuums and other supported devices through Port OS cloud. Give ChatGPT, Claude and other MCP-compatible assistants access to the devices you connect. Turn off the living room lights, play music on your speakers, adjust the thermostat, run a vacuum in a room, check a camera snapshot or find a connected tracker. Available actions depend on your linked provider accounts and each device’s supported capabilities. Port OS runs in the cloud; no local server is required. You choose the account, device and capability permissions each assistant receives. Device operations require user OAuth; public tool discovery does not grant device access. Port OS is in alpha. Setup: https://portoperatingsystem.com/docs/getting-started/ Support: https://portoperatingsystem.com/contact/
Control your Tesla from your AI assistant - climate, charging, access, and security.
Image and video AI tools and your own pipelines, run from any AI assistant.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables comprehensive control and monitoring of Home Assistant smart home devices, automations, scenes, and system management through AI assistants. Supports lights, climate, media players, notifications, history tracking, and advanced automation workflows.2MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to interact with Home Assistant smart home devices through natural language. Control devices, manage automations, query entity states, and retrieve historical data across your home automation system.1MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI assistants to interact with Home Assistant to control smart home devices, query entity states, and manage automations using natural language. It provides over 90 tools for comprehensive system management, including dashboard configuration, service execution, and automation debugging.MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to control Home Assistant via natural language, including device control, automation management, and system monitoring.MIT