Yeelight IoT MCP Server — Claude Code MCP server for smart lights
Wires an AI client into the Yeelight Pro cloud: browse homes, rooms and devices, read live state, run scenes.
claude mcp add --transport http yeelight-iot-mcp-server https://api.yeelight.com/apis/mcp_server/v1/mcpWhat Yeelight IoT MCP Server does
Eight tools cover topology discovery (homes, areas, rooms, devices, groups, scenes), capability reads, safe control preparation and confirmed execution. Lists come back with cursor pagination. Device control and scene runs start as dry-runs, so the agent lays out a plan and waits for your explicit go-ahead before anything changes.
Transport is Streamable HTTP. You can point a client at the hosted endpoint https://api.yeelight.com/apis/mcp_server/v1/mcp or run the source deployment yourself. Local runs need Python 3.10 or later and uv, and they still call Yeelight cloud APIs — this is not an offline gateway. Every request has to carry an Authorization header with a Yeelight token; without it the server answers nothing, whatever address it is bound to. Region and House ID are optional: the region falls back to a JWT claim, and the first Pro home in that region is picked when House ID is absent.
The yeelight-home setup flow prints a QR code you scan in the Yeelight Pro app to get a token. The same setup brings in Metadata MCP alongside this server. If an existing integration already calls control_node or execute_scene, leave it as is.
What it helps with
- list every room and device in a Yeelight Pro home
- check a lamp's current state before sending a command
- turn lights on through the agent instead of the phone app
- run a scene after reviewing the proposed plan
- page through groups and scenes in a large home
Example prompts for the agent
- Show me all rooms and devices in my Yeelight home
- Draft a plan to switch off the bedroom lights, don't execute yet
- Run the Evening scene in the living room
How to install Yeelight IoT MCP Server
Platform CLI: remote server
claude mcp add --transport http yeelight-iot-mcp-server https://api.yeelight.com/apis/mcp_server/v1/mcpPlatform CLI: remote server
codex mcp add yeelight-iot-mcp-server --url https://api.yeelight.com/apis/mcp_server/v1/mcpConfig file
{
"mcpServers": {
"yeelight-iot-mcp-server": {
"url": "https://api.yeelight.com/apis/mcp_server/v1/mcp"
}
}
}Config file
{
"servers": {
"yeelight-iot-mcp-server": {
"type": "http",
"url": "https://api.yeelight.com/apis/mcp_server/v1/mcp"
}
}
}Platform CLI: remote server
gemini mcp add -t http yeelight-iot-mcp-server https://api.yeelight.com/apis/mcp_server/v1/mcpStep by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about Yeelight IoT MCP Server
How do I install Yeelight IoT MCP Server in Claude Code?
Run claude mcp add --transport http yeelight-iot-mcp-server https://api.yeelight.com/apis/mcp_server/v1/mcp. Restart the MCP client after the config changes.
What does Yeelight IoT MCP Server do?
It exposes smart-home topology and live device state to the agent, plus the control_node and execute_scene tools for switching lights and firing scenes.
What do I need before running it?
A Yeelight authorization token in the Authorization header, or requests will not go through. A local deployment also needs Python 3.10 or later and uv.