Where commands run

Open the command window on your computer

This page never runs commands for you. Open the matching app, paste one copied command, then press Enter.

Open Terminal on macOS

  1. Press Command and Space together.
  2. Type Terminal.
  3. Press Enter to open it, then paste the command you copied.

Open PowerShell on Windows

  1. Press the Windows key.
  2. Type PowerShell.
  3. Open Windows PowerShell, then paste the command you copied.
Run one command at a time. Wait for it to finish before copying the next one.
Back to the ecosystem

Install Yeelight Home and connect your home

Install the Yeelight Home CLI, authorize with the Yeelight Pro app, choose a home by name, and complete a real read-only check. You do not copy a token or install a Skill or MCP yet.

Estimated time
12 minutes
What success looks like
Yeelight Home passes diagnostics, authorization is valid, a home is selected by name, and real room and device lists can be read.
Before you start
  • Node.js, npm, and npx each print a version; use the linked prerequisite guide if they do not
  • Signed in to the Yeelight Pro app with the target home visible
  • The computer and phone can reach the Yeelight service for the account region
Privacy boundary

Sign-in and QR scanning stay on your computer. Never send a token, password, cookie, verification code, or QR result to an AI assistant.

Check the computer environment first

Yeelight Home is installed with npm, so Node.js, npm, and npx must already work. npm and npx arrive with Node.js LTS and are not separate downloads.

Run these one at a time. If any command does not print a version, use the Complete first link at the top of this page, then return here.

1. Check Node.js
shell
node --version
Execution preview

node --version

    Interactive demo only. It does not run a command or connect to a device.

    2. Check npm
    shell
    npm --version
    Execution preview

    npm --version

      Interactive demo only. It does not run a command or connect to a device.

      3. Check npx
      shell
      npx --version
      Execution preview

      npx --version

        Interactive demo only. It does not run a command or connect to a device.

        You are done whenEach command prints a version. Your exact numbers may differ.

        If it did not workIf a command is missing, stop here. Complete the computer environment guide and reopen Terminal or PowerShell.

        Check the account and home in the app

        Open the Yeelight Pro app and confirm that the home you want to connect is visible. Authorization uses the current app account. The first experience is read-only, so you do not need to change administrator permissions first.

        Know the account region. Mainland China normally uses `cn`; Singapore, the United States, and Europe use `sg`, `us`, and `eu`. The QR code does not detect this automatically.

        You are done whenThe target home and at least one room or device are visible in the app.

        If it did not workSign in with the correct account or ask the home administrator to invite it. Never send account passwords to this guide or an AI assistant.

        Easiest: ask AI to install Yeelight Home

        Use this request when your AI can run local commands. It installs only the Yeelight Home CLI covered by this guide and does not add a Skill or MCP.

        Ask AI to install and connect Yeelight Home
        Install and verify the official Yeelight Home CLI for me. First run node --version, npm --version, and npx --version one at a time; if one is missing, guide me through Node.js LTS first. When all three work, use npm install --global yeelight-home. In mainland China use npm install --global yeelight-home --registry=https://registry.npmmirror.com instead. Verify with yeelight-home version --json. Ask which Yeelight account region I use: cn for mainland China, sg for Singapore, us for the United States, or eu for Europe. Run yeelight-home auth login --qr --region with that value and wait while I scan from Yeelight Pro app Home, top-right +, MCP Authorization. After authorization, run yeelight-home home select and let me choose by home name; do not ask me to find a House ID. Finish with yeelight-home doctor --json, yeelight-home room list --json, and yeelight-home device list --json, reporting only sanitized real results. Do not install a Skill or configure MCP in this task. Never request or display a token, QR payload, cookie, or device identifier. If something fails, report the real error and next recovery command instead of guessing.
        You

        Install and verify the official Yeelight Home CLI for me. First run node --version, npm --version, and npx --version one at a time; if one is missing, guide me through Node.js LTS first. When all three work, use npm install --global yeelight-home. In mainland China use npm install --global yeelight-home --registry=https://registry.npmmirror.com instead. Verify with yeelight-home version --json. Ask which Yeelight account region I use: cn for mainland China, sg for Singapore, us for the United States, or eu for Europe. Run yeelight-home auth login --qr --region with that value and wait while I scan from Yeelight Pro app Home, top-right +, MCP Authorization. After authorization, run yeelight-home home select and let me choose by home name; do not ask me to find a House ID. Finish with yeelight-home doctor --json, yeelight-home room list --json, and yeelight-home device list --json, reporting only sanitized real results. Do not install a Skill or configure MCP in this task. Never request or display a token, QR payload, cookie, or device identifier. If something fails, report the real error and next recovery command instead of guessing.

        This guide installs the local foundation and performs read-only checks. Credentials remain on this computer. Sanitized interactive demo. It does not read your home or control a device.

        You are done whenThe AI reports the real version, authorization state, selected home name, and read-only results rather than only saying installed.

        If it did not workContinue with the npm step when the AI cannot run local commands.

        Install it yourself: one npm path for Windows and macOS

        Both systems use npm. Use the official registry outside mainland China. The npmmirror command is available for mainland China and affects only this installation. Choose one command, not both.

        Official npm registry
        shell
        npm install --global yeelight-home
        Execution preview

        npm install --global yeelight-home

          Interactive demo only. It does not run a command or connect to a device.

          Mainland China: one-command mirror
          shell
          npm install --global yeelight-home --registry=https://registry.npmmirror.com
          Execution preview

          npm install --global yeelight-home --registry=https://registry.npmmirror.com

            Interactive demo only. It does not run a command or connect to a device.

            This line is from a real installation. Time and package counts can change.

            Verify installation (real output shape)
            shell
            yeelight-home version --json
            Execution preview

            yeelight-home version --json

              Interactive demo only. It does not run a command or connect to a device.

              This sample is from one real macOS installation. Version, OS, and architecture vary.

              You are done whenThe version response identifies `yeelight-home` and reports the installed version and platform.

              If it did not workReopen the command window if `yeelight-home` is missing. If needed, inspect `npm prefix --global`; do not add sudo blindly.

              Choose the account region, then scan

              The region must match the Yeelight Pro account. Mainland China normally uses `cn`; Singapore, United States, and Europe accounts use `sg`, `us`, and `eu`. The terminal defaults to a compact QR. Change `compact` to `normal` or `large` if scanning is difficult.

              Most people need only one command. Keep the terminal open, then choose Home -> top-right `+` -> `MCP Authorization` in the Yeelight Pro app and confirm on the phone.

              Mainland China
              shell
              yeelight-home auth login --qr --region cn
              Execution preview

              yeelight-home auth login --qr --region cn

                Interactive demo only. It does not run a command or connect to a device.

                Singapore
                shell
                yeelight-home auth login --qr --region sg
                Execution preview

                yeelight-home auth login --qr --region sg

                  Interactive demo only. It does not run a command or connect to a device.

                  United States
                  shell
                  yeelight-home auth login --qr --region us
                  Execution preview

                  yeelight-home auth login --qr --region us

                    Interactive demo only. It does not run a command or connect to a device.

                    Europe
                    shell
                    yeelight-home auth login --qr --region eu
                    Execution preview

                    yeelight-home auth login --qr --region eu

                      Interactive demo only. It does not run a command or connect to a device.

                      English guide to MCP Authorization in the Yeelight Pro app plus menu
                      Actual path: Yeelight Pro app Home -> top-right `+` -> MCP Authorization.
                      Complete QR sign-in Guided example
                      Read the transcript

                      The terminal creates a compact QR for the chosen account region. The user opens MCP Authorization in the Yeelight Pro app and confirms. The recording contains no real QR code, home name, or credential.

                      Treat the QR as temporary authorization. Do not forward screenshots, tokens, cookies, or QR results.

                      You are done whenThe terminal confirms that credentials were saved for the correct region.

                      If it did not workRun the same command again if the QR expires. Authentication failure or an empty home list often means the selected region is wrong.

                      Choose the home directly by name

                      Run `home select` with no identifier. The terminal lists accessible home names and accepts a number or full name. Yeelight Home stores the internal House ID for later commands.

                      Open home selection
                      shell
                      yeelight-home home select
                      Execution preview

                      yeelight-home home select

                        Interactive demo only. It does not run a command or connect to a device.

                        Confirm authorization and saved home context
                        shell
                        yeelight-home auth status --json
                        Execution preview

                        yeelight-home auth status --json

                          Interactive demo only. It does not run a command or connect to a device.

                          You are done whenThe terminal confirms the selected home. Most later commands no longer need home information.

                          If it did not workRun the command in a real Terminal or PowerShell window if it says an interactive terminal is required. An empty list usually means the region or app permission is wrong.

                          House ID is for automation only

                          `yeelight-home home select --house-id <id>` remains available for scripts. Ordinary users should use the name-based interactive path.

                          Confirm installation with real read-only results

                          Run doctor, then read rooms and devices. These commands were verified against a signed-in home. They do not control a light or modify the home.

                          1. Check installation, authorization, and home
                          shell
                          yeelight-home doctor --json
                          Execution preview

                          yeelight-home doctor --json

                            Interactive demo only. It does not run a command or connect to a device.

                            2. Read real rooms
                            shell
                            yeelight-home room list --json
                            Execution preview

                            yeelight-home room list --json

                              Interactive demo only. It does not run a command or connect to a device.

                              3. Read real devices
                              shell
                              yeelight-home device list --json
                              Execution preview

                              yeelight-home device list --json

                                Interactive demo only. It does not run a command or connect to a device.

                                You are done whenDoctor reports `ok`, and both list commands report `success` with real content from the selected home.

                                If it did not workFollow doctor remediations for warnings. Reauthorize and choose the home again when reads fail. One device lacking readable state does not invalidate a successful room and device list.

                                Experience what Yeelight Home actually provides

                                Yeelight Home works for AI and direct human use. The console guides you through homes, rooms, devices, and scenes and asks again before light or scene execution, so you do not write complex parameters.

                                Open the bilingual home console
                                shell
                                yeelight-home menu
                                Execution preview

                                yeelight-home menu

                                  Interactive demo only. It does not run a command or connect to a device.

                                  Try the built-in Yeelight product knowledge
                                  shell
                                  yeelight-home product search --keyword skylight --json
                                  Execution preview

                                  yeelight-home product search --keyword skylight --json

                                    Interactive demo only. It does not run a command or connect to a device.

                                    Let AI understand the home read-only
                                    Use the Yeelight Home CLI already installed on my computer. Read the current rooms, devices, scenes, and automations and explain the home's smart-lighting capabilities in everyday language. Do not control a device or change the home yet.
                                    You

                                    Use the Yeelight Home CLI already installed on my computer. Read the current rooms, devices, scenes, and automations and explain the home's smart-lighting capabilities in everyday language. Do not control a device or change the home yet.

                                    All four operations are read-only; the AI does not need the QR, token, or device IDs. Sanitized interactive demo. It does not read your home or control a device.

                                    Begin with reads or previews. Confirm the home, room, and target before actual control; perform home-management changes only after understanding their impact.

                                    You are done whenAI returns a real home summary, or the console shows current home resources. Product search also returns real reference material without writing to the home.

                                    If it did not workKeep the phrase 'use the Yeelight Home CLI on my computer' if AI does not know the tool. Continue to the Skill guide for complete Yeelight rules, or the Yeelight MCP guide for standard MCP access.

                                    Try these everyday scenarios first

                                    Start with three to five easy examples. Every sentence is ready to send to your AI.

                                    01

                                    Understand this home

                                    Use the Yeelight Home CLI on this computer. Summarize the current rooms, devices, scenes, and automations in everyday language. Read only.

                                    What you will seeA real home summary with zero writes.
                                    02

                                    See what is in the living room

                                    Use the local Yeelight Home CLI to read the living-room lights, groups, and scenes. Do not control anything.

                                    What you will seeA clear list of real living-room resources.
                                    03

                                    Preview before turning lights on

                                    Use the local Yeelight Home CLI to preview turning on the living-room lights and tell me which lights would change. Do not execute yet.

                                    What you will seeA dry-run preview with unchanged devices.
                                    04

                                    Find a suitable scene

                                    Use the local Yeelight Home CLI to read my scenes and suggest one for watching TV at night. Do not execute it.

                                    What you will seeA recommendation from scenes that actually exist in this home.
                                    More complete scenarios
                                    05

                                    Understand a Yeelight product

                                    Use Yeelight Home product knowledge to search for a skylight panel and explain where it fits in plain language.

                                    What you will seeProduct information clearly separated from installed devices.
                                    06

                                    Review automation coverage

                                    Use the local Yeelight Home CLI to list automations read-only, group them by room, and show which are enabled.

                                    What you will seeAutomation state organized by room without enabling or changing anything.
                                    07

                                    Inspect the gateway without control

                                    Use the local Yeelight Home CLI to inspect the current gateway summary and diagnostics. Do not control devices.

                                    What you will seeGateway capability and recovery guidance based on real results.

                                    Troubleshooting

                                    Does this page install a Skill or MCP?

                                    No. It installs Yeelight Home CLI, authorizes it, and verifies the home. Continue to the Skill guide for full Yeelight rules or the Yeelight MCP guide for standard MCP access.

                                    Do I download npm and npx separately?

                                    No. A supported Node.js LTS installation includes both. Use the linked computer environment guide if any of the three version checks fail.

                                    What if npm download is slow or times out?

                                    In mainland China use `npm install --global yeelight-home --registry=https://registry.npmmirror.com`. That registry applies only to this command.

                                    What do EACCES, EPERM, or permission errors mean?

                                    Close software holding npm files and confirm Node.js was installed normally for this user. Do not add sudo blindly. Reopen PowerShell on Windows or inspect `npm prefix --global` on macOS.

                                    Why is yeelight-home missing after npm succeeds?

                                    Reopen Terminal or PowerShell to refresh PATH. Inspect `npm prefix --global` and `npm root --global`; doctor also reports actual paths and remediations.

                                    Does QR sign-in detect the region?

                                    No. Use `cn` for mainland China, `sg` for Singapore, `us` for the United States, and `eu` for Europe. A wrong region often causes authorization failure or an empty home list.

                                    What if the QR is difficult to scan?

                                    The default is compact. Add `--qr-size normal` or `--qr-size large`. You can also add `--qr-png <path>` to create a local PNG; never forward it.

                                    What if the QR expires or the terminal never changes?

                                    Press Ctrl+C and rerun the command for the same region. Confirm the phone completed MCP Authorization rather than only opening the camera.

                                    Why does home select require an interactive terminal?

                                    It is running in a background or non-interactive script. Open a real Terminal or PowerShell window and run the command directly.

                                    What does path_lookup_differs_from_running_executable mean?

                                    An old terminal may resolve a different copy. Upgrade with `npm install --global yeelight-home@latest`, reopen the terminal, and follow doctor remediation with `command -v yeelight-home` or `Get-Command yeelight-home`.

                                    Device list works but one device has no readable state. Is installation broken?

                                    Not necessarily. It may be offline, unbound, or expose no readable property. Use successful doctor, room list, and device list as the first installation gate, then diagnose that device separately.

                                    Why do some home-management actions require an administrator?

                                    Reading rooms and devices usually does not. Creating, deleting, member management, and some configuration are higher-impact actions and require a home administrator.

                                    Do I start Python, an MCP server, or another service?

                                    Not for this guide. The Yeelight Home CLI runs directly. Later Skill or MCP setup lets the relevant client invoke it when needed.

                                    Keep exploring with the community

                                    Get practical setup help, exchange ideas, and follow what is next for Yeelight AI.

                                    WhatsApp

                                    Yeelight AI Community

                                    Meet other Yeelight AI users and get help with your setup.

                                    Scan with WhatsApp or open the group directly.
                                    WhatsApp

                                    Yeelight AI Community

                                    QR code for the Yeelight AI Community on WhatsApp

                                    Scan with WhatsApp or open the group directly.