-
Notifications
You must be signed in to change notification settings - Fork 386
Homebridge on Windows 10
This guide provides step-by-step instructions to show you how to install Homebridge on Windows 10 as a service so it will automatically start on boot.
- Prerequisites
- Install Homebridge
- Manage and Configure Homebridge
- How To Uninstall Homebridge
- Multiple Instances
- Additional Utilities
- Major Node.js Version Updates
- Configuration Reference
Before you get started, make sure you have the following ready:
- A computer running an update-to-date version of Windows 10 (this guide is based on 1903).
- An account with Administrator Privileges.
Homebridge requires Node.js install on your system to run. Download the LTS version of Node.js (v14.16.0) and run the installer with all the default options selected:
Open a new Node.js Command Prompt window as administrator, then check that Node.js and NPM have installed correctly by running the following commands:
# test node.js is working
node -v
# test npm is working
npm -v
From the administrator Node.js command prompt, run the following command to install Homebridge and the Homebridge UI:
npm install -g --unsafe-perm homebridge homebridge-config-ui-x
To install Homebridge as a service we use the hb-service
command provided by the Homebridge UI plugin:
hb-service install
If you see a Windows Firewall warning, make sure you grant Node.js permissions to access your private network.
To access the Homebridge UI go to http://localhost:8581
in your browser.
The default username is admin with password admin.
The Homebridge UI will allow you to install, remove and update plugins, and modify the Homebridge config.json
.
Review the Configuration Reference at the bottom of this guide.
To view your pairing QR code, you'll need to view the logs which are stored in the $HOME\.homebridge\homebridge.log
file. You can view the from a Node.js command prompt with this command:
hb-service logs
To edit your config.json
file you can open the $HOME\.homebridge\config.json
file in a code editor of your choosing (VS Code is a good option with syntax checking).
Do not edit the config.json
file using the a word processor that does text formatting as this will corrupt the file.
After making any changes to your config.json
you need to restart Homebridge using by stopping and starting the service in Task Manager. You can also run this command from a Node.js command prompt:
hb-service stop
hb-service start
Delete the service run the following command from a Node.js administrator command prompt:
hb-service uninstall
Remove Homebridge and Homebridge Config UI X:
npm uninstall -g homebridge homebridge-config-ui-x
You can optionally delete all Homebridge data stored in $HOME\.homebridge
and uninstall Node.js.
💡 Homebridge now supports Child Bridges which are an easier to manage alternative to running multiple instances.
Some users like to run multiple instances of Homebridge.
The hb-service
command makes this easy to do via the --service-name
flag.
See the hb-service
documentation for instructions.
Some plugins may require you to have git
installed, or the windows-build-tools
to compile native modules.
While installing certain plugins you may encounter the spawn git ENOENT
or ENOGIT
error. To resolve this issue you need to install the git
utility. You can download the installer from https://git-scm.com/downloads.
The windows-build-tools
allow Homebridge plugins to compile native code for your platform. While increasingly rare, some plugins will require this. To install the windows-build-tools
open a Node.js command prompt as an Administrator and run:
npm install --global windows-build-tools
It is recommended to run Homebridge on the current stable LTS version of Node.js. You can download the new releases from the Node.js website.
After updating Node.js, run this command to rebuild the modules:
hb-service rebuild
This command can take a very long time to run. Be patient.
This table contains important information about your setup. You can use the information provided here as a reference when configuring or troubleshooting your environment after setting up Homebridge using the instructions below.
File Location / Command | |
---|---|
Config File Path | %HOMEPATH%\.homebridge\config.json |
Storage Path | %HOMEPATH%\.homebridge |
Restart Command | hb-service restart |
Stop Command | hb-service stop |
Start Command | hb-service start |
View Logs Command | hb-service logs |
- Raspberry Pi
- Debian, Ubuntu
- CentOS, Fedora, Red Hat
- Arch, Manjaro
- macOS
- Windows 10 / 11 (Hyper-V)
- Docker
- Synology DSM 7
- Other Platforms
- Basic Troubleshooting
- Backup and Restore
- Child Bridges
- Config File
- Connect To HomeKit
- FFmpeg for Homebridge
- HomeKit Glossary of Terms
- iOS Homemanager App
- mDNS Options
- Remote Access
- Useful Links
- Basic Troubleshooting
- Config Options
- Enabling Accessory Control
- Enabling UI with Docker
- Homebridge Service Command
- Manual Configuration
- Reverse Proxy: Apache
- Reverse Proxy: Nginx and SSL
- Standalone Mode
- Swap From Standalone To Service Mode
- Developer Docs
- API Reference
- Plugin Templates
- Other Links (Internal)
- Other Links (External)